mirror of
https://github.com/intel/llvm.git
synced 2026-01-19 09:31:59 +08:00
[ELF] Set MAXPAGESIZE to 2MiB on x86-64 to match bfd and gold.
The FreeBSD kernel relies on this behavior to not overwrite the boot loader. llvm-svn: 278889
This commit is contained in:
@@ -1138,8 +1138,10 @@ Expr ScriptParser::readExpr1(Expr Lhs, int MinPrec) {
|
||||
}
|
||||
|
||||
uint64_t static getConstant(StringRef S) {
|
||||
if (S == "COMMONPAGESIZE" || S == "MAXPAGESIZE")
|
||||
if (S == "COMMONPAGESIZE")
|
||||
return Target->PageSize;
|
||||
if (S == "MAXPAGESIZE")
|
||||
return Target->MaxPageSize;
|
||||
error("unknown constant: " + S);
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user