[PATCH] D61694: Boilerplate for producing XCOFF object files from the PowerPC backend.

Nico Weber via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 3 06:33:54 PDT 2019


thakis added inline comments.


================
Comment at: llvm/lib/MC/XCOFFObjectWriter.cpp:68
+  // Timestamp converted to an int32_t.
+  W.write<int32_t>(Now);
+  // Byte Offset to the start of the symbol table.
----------------
hfinkel wrote:
> sfertile wrote:
> > hfinkel wrote:
> > > Will the tools on AIX complain if this is 0? Our general policy is that the compiler's output should be deterministic/reproducible and this breaks that. Looks like D23934 was never finished, but this value should be tied to that (once it's finished).
> > > 
> > No a zero value should be fine. Is the goal the compiler always produces reproducible output by default, or just that we can enable reproducible output with an option?
> Interesting question. I'd say by default, but I don't know that we've had a situation before where the platform default is to produce non-reproducible outputs at a low level (e.g., in the object-file format).
> 
> I recommend that we just set this to zero for now, and then have a separate discussion on how to change this later as necessary and/or desired.
> 
If 0 works fine here, then go with that. But there's precedent for writing the current time into the output by default: clang-cl does that, since link.exe /incremental silently mislinks if that field is 0. So we do the safe thing by default and only write a 0 if the user explicitly passes /Brepro to clang-cl (which finally makes Asm.isIncrementalLinkerCompatible() return false here: http://llvm-cs.pcc.me.uk/lib/MC/WinCOFFObjectWriter.cpp#1057 )


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D61694/new/

https://reviews.llvm.org/D61694





More information about the llvm-commits mailing list