lighthouse/book/src
Michael Sproul 7d8acc20a0 Add a flag to make lighthouse portable across machines (#1423)
## Issue Addressed

Closes #1395

## Proposed Changes

* Add a feature to `lighthouse` and `lcli` called `portable` which enables the `portable` feature on our fork of BLST. This feature turns off the `-march=native` C compiler flag that produces binaries highly targeted to the host CPU's instruction set.
* Tweak the `Makefile` so that when the `PORTABLE` environment variable is set to `true`, it compiles with this feature.
* Temporarily enable `PORTABLE=true` in the Docker build so that the image on Docker Hub is portable. Eventually I think we should enable `PORTABLE=true` _only on Docker Hub_, so that users building locally can take advantage of the tasty compiler magic. This seems to be possible by setting a Docker Hub environment variable: https://docs.docker.com/docker-hub/builds/#environment-variables-for-builds

## Additional Info

Tested by compiling on a very new CPU (Intel Core i7-8550U) and copying the binary to a very old CPU (Intel Core i3 530). Before the portability fix, this produced the SIGILL crash described in #1395, and after the fix, it worked smoothly.

I'm in the process of testing the Docker build and running some benches to confirm that the performance penalty isn't too severe.
2020-07-31 05:00:39 +00:00
..
css Make API friendly to block explorers (#702) 2019-12-19 11:45:28 +11:00
http Add support for multiple testnet flags (#1396) 2020-07-29 06:39:29 +00:00
js Add support for multiple testnet flags (#1396) 2020-07-29 06:39:29 +00:00
advanced_database.md Document the freezer DB space-time trade-off (#808) 2020-01-20 10:01:58 +11:00
advanced.md Document the freezer DB space-time trade-off (#808) 2020-01-20 10:01:58 +11:00
api.md Refactor docs into mdbook (#547) 2019-10-02 11:04:56 +10:00
become-a-validator-docker.md Book modifications to include testnet param (#1418) 2020-07-31 02:14:50 +00:00
become-a-validator-source.md Book modifications to include testnet param (#1418) 2020-07-31 02:14:50 +00:00
become-a-validator.md Book modifications to include testnet param (#1418) 2020-07-31 02:14:50 +00:00
cli.md Minor useability updates (#1005) 2020-04-15 17:46:03 +10:00
contributing.md Update CONTRIBUTING.md (#751) 2020-01-03 10:45:53 +11:00
docker.md Add a flag to make lighthouse portable across machines (#1423) 2020-07-31 05:00:39 +00:00
faq.md Correct book links (#1338) 2020-07-07 17:28:59 +10:00
http.md Update HTTP API docs (#1010) 2020-04-16 20:31:43 +10:00
installation.md Add raspberry pi docs (#1252) 2020-06-10 17:11:57 +10:00
intro.md Fix issues with testnet dir, update docs (#992) 2020-04-17 17:49:29 +10:00
key-managment.md Doc updates (#1226) 2020-06-01 11:34:16 +10:00
local-testnets.md Update local testnet scripts, fix eth1 sim (#1184) 2020-05-26 18:30:44 +10:00
pi.md Add raspberry pi docs (#1252) 2020-06-10 17:11:57 +10:00
setup.md Directory Restructure (#1163) 2020-05-18 21:24:23 +10:00
SUMMARY.md Book modifications to include testnet param (#1418) 2020-07-31 02:14:50 +00:00
validator-create.md Book modifications to include testnet param (#1418) 2020-07-31 02:14:50 +00:00
validator-import-launchpad.md Add EF launchpad import (#1381) 2020-07-29 04:32:50 +00:00
validator-management.md Introduce validator definition file for VC (#1357) 2020-07-22 09:34:55 +00:00
wallet-create.md Wallet-based, encrypted key management (#1138) 2020-05-18 19:01:45 +10:00
websockets.md Testnet5 docs (#892) 2020-03-05 10:12:34 +11:00