mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-01 05:01:59 +01:00
[stackprotector] Add in the stackprotector libcall.
We support this libcall on all platforms except for OpenBSD (See lib/Codegen/StackProtector.cpp). llvm-svn: 188193
This commit is contained in:
parent
e32ebb94bd
commit
defd024179
@ -354,6 +354,9 @@ namespace RTLIB {
|
|||||||
SYNC_FETCH_AND_NAND_4,
|
SYNC_FETCH_AND_NAND_4,
|
||||||
SYNC_FETCH_AND_NAND_8,
|
SYNC_FETCH_AND_NAND_8,
|
||||||
|
|
||||||
|
// Stack Protector Fail.
|
||||||
|
STACKPROTECTOR_CHECK_FAIL,
|
||||||
|
|
||||||
UNKNOWN_LIBCALL
|
UNKNOWN_LIBCALL
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -361,6 +361,13 @@ static void InitLibcallNames(const char **Names, const TargetMachine &TM) {
|
|||||||
Names[RTLIB::SINCOS_F128] = 0;
|
Names[RTLIB::SINCOS_F128] = 0;
|
||||||
Names[RTLIB::SINCOS_PPCF128] = 0;
|
Names[RTLIB::SINCOS_PPCF128] = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (Triple(TM.getTargetTriple()).getOS() != Triple::OpenBSD) {
|
||||||
|
Names[RTLIB::STACKPROTECTOR_CHECK_FAIL] = "__stack_chk_fail";
|
||||||
|
} else {
|
||||||
|
// These are generally not available.
|
||||||
|
Names[RTLIB::STACKPROTECTOR_CHECK_FAIL] = 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// InitLibcallCallingConvs - Set default libcall CallingConvs.
|
/// InitLibcallCallingConvs - Set default libcall CallingConvs.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user