New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
x64: build a Position-Independent Executable (PIE) #2358
Conversation
Mh, other than the broken builders, wasn't there a difference in hardened GCCs that uses a different command line switch for this? Might not be PIE tho, can't remember atm (but it was related to not working on hardened). |
You're most like thinking of the -fno-pie flag that we were looking at. |
Sounds like it. Guess this clears that up :) |
3a62773
to
3280987
Compare
I'm very weary about getHeapOp explicitly using a scratch register. Sounds like a good way to introduce bugs. Especially since it only uses the scratch register sometimes at random. |
@phire Dropped that function. |
Note to self: If we ever want to run multiple CPUs in parallel with the same block cache, we'll get problems with PIE. |
Anything still missing? |
Didn't change anything, just rebased to current master. Should be ready. |
@@ -169,16 +169,17 @@ void Jit64AsmRoutineManager::Generate() | |||
TEST(32, R(RSCRATCH), R(RSCRATCH)); | |||
FixupBranch notfound = J_CC(CC_L); | |||
//grab from list and jump to it | |||
u64 codePointers = (u64)jit->GetBlockCache()->GetCodePointers(); | |||
if (codePointers <= INT_MAX) | |||
const u8** codePointers = jit->GetBlockCache()->GetCodePointers(); |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
a3a41e6
to
a143a05
Compare
x64: build a Position-Independent Executable (PIE)
Revert "Merge pull request #2358 from Tilka/pie"
This is needed to run on x86_64 OSes that require PIC for strong ASLR, e.g. Android or Hardened Gentoo (issue 7467).
I feel like I forgot something, can't remember what...