Re:Mrustc: a Rust compiler written in C++
by kibwen on Friday September 22, 2017 @12:31AM
(#15309402)
Be careful, let's not forget the lesson of Ken Thompson's Reflections on Trusting Trust. It's more accurate to say that compilation is a function that takes two arguments: the source code, and the compiler itself; this is how trusting-trust attacks propagate despite total absence from the source code.
[ Parent
| on HN ]
Re:Mrustc: a Rust compiler written in C++
by weberc2 on Friday September 22, 2017 @10:58AM
(#15312754)
You're being pedantic, but your pedantry is incorrect, so allow me to be pedantic in correcting you :p. The output of all pure functions depends on the function and its inputs; this isn't more true for compilers than, say, addition. The problem with Trusting Trust is that the function isn't practically inspectable, not that the function is impure. A trusting trust compiler is still pure.
Re:Mrustc: a Rust compiler written in C++
by falcolas on Friday September 22, 2017 @12:26PM
(#15313565)
A functionally pure compiler would always provide the same output for the given source code. The challenges in creating repeatable builds of highly popular open source projects shows that the average compiler is anything but functionally pure. The global state of the system running the compiler has a huge impact on the output of the compiler.