What is Fault Tolerant Write? - uefi

Inspect UEFI code recently, one of the modules is FaultTolerantWritePei.inf, never understand this knowledge.
I tried using a search engine, but I didn't find anything particularly correct and specific.

Related

(x64) Where can I find CPU instructions usage statistics in contemporary programs?

I'm looking for some statistics which would tell me/show how frequently each instruction from x64 instruction set is used overall in modern programs. I have done some google searches, but I can't find any phrase that would give me anything else than "instruction performance statistics", so I'm asking if, by any chance, someone here knows of something like what I'm trying to find.
I'm trying to find info like this because I'm working on my own 64bit CPU (as an interesting excercise, no other ambitions, so don't worry), and beyond the obvious basic instructions that I know are necessary, I'm aware that x64 processors have a huge amount of instructions from... say... exotic to downright (to me) absurdly weird operations. I therefore I would like to know how often are which used in actual programs, so that I can prioritize which one to learn more about and possibly add to my own CPU, based on the assumption that the most used/occuring ones in existing compiled code, even if they seem weird to me, are actually useful.
If nothing of that sort exists, could you at least point me to some kind of disassembler/analyzer which I can use myself, point it at a program/dll, and it would be able to show me instruction usage stats for it?

Julia 0.6 to Postgres connection - Available options and LibPq.jl

I was with Julia 0.5 and used PostgreSql.jl to connect to the Database. It internally uses DBI.jl dependency.
Now upgrading to version 0.6, this has stopped working. The only alternative I could find online is LibPQ.jl. However, the library is a huge inconvenience to use.
Does anyone here have experience with connecting to Postgres from Julia? How did you achieve it?
Please shoot any questions if I have missed giving any information.
I achieved it by writing and using PostgreSQL.jl, and later LibPQ.jl. PostgreSQL.jl was very much a novice effort, and I stand by LibPQ.jl as the better option. Briefly in development we used ODBC.jl, but found that difficult to configure, inflexible in output, and slow. Using LibPQ.jl has simplified our database interaction code and improved transfer speeds.
I found it more useful to write a package that supported an existing general data interface (DataStreams.jl) than to write and maintain a database interface that I wasn't personally invested in. There's certainly opportunity to do so, and to support the interface using LibPQ.jl, but it is no longer a personal goal of mine.
I am also happy to discuss any inconvenience you have using LibPQ.jl in an appropriate forum (tagging me on the JuliaLang Discourse site always gets a response).

Deploy Erlang Application

I would like to run Erlang application on a centOS server for stress testing. I would like to know what I must accomplish to deploy a Erlang application before I send it to the server admin to install and run.
What will I need to tell my admin to properly run an Erlang app on a server? (Basically how can I send him a file and give him an really stupid easy instructions to install it?)
Is their a way to send my app in a executable format that the admin can easily install with? Kinda like PyPy?
How can I perform code swapping? Will the app need to be in it's code state still in order to do this?
I would appreciate any help to make this process easy. Thank you!
For anyone just passing by: Even though this is my first Erlang app, I highly recommend anyone wanting to build a easy to scale server user Erlang. The benefits are amazing, if you know how to use Erlang properly.
Cheers!
The usual way of deploying an Erlang program (I'm avoiding the word application here, as it's somewhat ambiguous in an Erlang context) involves building a release (see this for some background). A release is essentially a packaging of your Erlang code (which often consists of multiple applications - hence the ambiguity) and the parts of the runtime system required to run it. The Erlang release system was designed with code upgrades in mind.
If you are using Rebar to build your program, you may find this article helpful. In addition to describing how to build a release (the process is a bit tricky) it also explains how you can deploy an upgrade.
A similar guide is also available for users of erlang.mk. If you're not using one of them already, or a comparable build tool, I strongly encourage you to do so as it makes release handling much less painful.
You may also find the answers to this question helpful. They list some additional options.

Catalyst::Engine::HTTP:Prefork

I am learning Catalyst from the book the definitive guide to catalyst. I have finished the demo application -- lolcatalyst_lite。 When I use command "CATALYST_ENGINE=HTTP:Prefork script/myapp_server.pl", something is wrong; and according to the book, I rewrite the file lite.pm, the wrong is still on.
I take back what I added in file lite.pm. Why the command "script/myapp_server.pl" is still wrong:
Catalyst::Engine::HTTP:Prefork' is not a module name
Compilation failed in require at /usr/local/share/perl/5.14.2/Catalyst/ScriptRunner.pm line 50.
Did I set some argument in operation system? How can I go back?
Catalyst has seen some pretty major changes under the hood since the book was published in this specific area.
The older Catalyst Engine code has been replaced with PSGI/Plack:
Catalyst used to contain an entire set of Catalyst::Engine::XXXX classes to handle various web servers and environments (e.g. CGI, FastCGI, mod_perl) etc.
This has been changed in Catalyst 5.9 so that all of that work is done by Catalyst implementing the PSGI specification, using Plack's adaptors to implement that functionality.
Have a look at the documentation for Catalyst::PSGI which explains why, and what to do with your existing code. The lolcat tutorial is quite current (v5.8), so you should be able to upgrade it without difficulty.

Webdevelopment in Common Lisp

I am somewhat familiar with Scheme. I am reading OnLisp, and would love to do a real world project in it. Most likely web development. I would love to know what kind of setup people use to develop websites in lisp. I have a couple of macs at home and I have figured I would use clozure cl. I am wary of a few things though. I have read on the internets that cl doesn't have reliable threading facility nor good networking. Is this true? What was your experience?
PS:Don't tell me about clojure :). Lisp is a itch I need to scratch.
Currently I'm using Restas a framework based on Hunchentoot and inspired by the route system of Rails. I also use Postmodern to interact with a PostgreSQL database and I generate HTML with cl-markup though I'm thinking about switching to cl-who which looks more customizable.
When I've started I've also considered using Parenscript to generate the JavaScript but now I'm just happy with Mootools and plain JavaScript.
Everything runs on SBCL and is available with Quicklisp.
Not sure why it wouldn't have "good networking"; you can't rely on threads if you want to write a portable Common Lisp application since certain implementations don't support them (AFAIK, just clisp, though you can compile it with experimental thread support). If you plan on picking an implementation and sticking with it, you won't have that problem.
The "standard" CL web stack is Hunchentoot/cl-who/clsql, though you can find tutorials that run on Araneida or Portable AllegroServe.
The setup I use is Debian/SBCL running quicklisp and the above systems along with MySQL (though I'm seriously considering jumping over to Postgres) for the database and nginx to run in front of Hunchentoot serving any static content.
mck- has been maintaining the heroku common lisp webapp.
https://github.com/mck-/heroku-cl-example/tree/
The problem with Common Lisp's "networking" is, we don't have sockets in CL standard, so each implementation has it's own socket API. We have some attempts to give a common interface though, like usocket. You can find a list of networking related packages here.
If you need a web framework, look into Caveman. I haven't used it yet but it looks like the most complete CL web framework I've ever seen.