[PATCH] WinCOFF: Transform IR expressions featuring __ImageBase into image relative relocations

Reid Kleckner rnk at google.com
Fri Jan 10 14:18:56 PST 2014


  I thought the imgrel32 relocation was for 32 bits of data, so wouldn't you have to pattern match a truncation to i32 around the subtraction?

  At that point, it might be better to just introduce some funky IR construct for globals that just gives you the 32 bit image offset of the symbol.  It's ugly, but there's some precedent for this kind of thing in x86_fp80 and ELF visibility, which aren't meaningful on all platforms.

http://llvm-reviews.chandlerc.com/D2523



More information about the llvm-commits mailing list