From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 7877) id 98DEA3858D1E; Mon, 27 Feb 2023 01:07:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 98DEA3858D1E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1677460044; bh=4l3h5PEotPqvpiOEXbkEALA8nUh15zEzC+EUUUcfx+M=; h=From:To:Subject:Date:From; b=q4qYCDcvxPH+zKu3istRBquBnJBxgnwZX2vusa2nmjEiqasmrpv1QR/F1Gmv/wExw V9a8GZSvFlvrvE1uGb7PheV1SKtpMOOd1qfR0eyODV6inQGgk/p4og7Olw/DTba8zQ fFth3DCd1szgVSt40q+8CsiZKbNDlO0dGylCcOzw= MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: LuluCheng To: gcc-cvs@gcc.gnu.org Subject: [gcc r13-6353] LoongArch: Change the value of macro TRY_EMPTY_VM_SPACE from 0x8000000000 to 0x1000000000. X-Act-Checkin: gcc X-Git-Author: Lulu Cheng X-Git-Refname: refs/heads/master X-Git-Oldrev: 2cd665b1a939c97fbf053d998cf687943bc07e47 X-Git-Newrev: 529e03b9882fe48cfa3c182abb12a5858a5762a2 Message-Id: <20230227010724.98DEA3858D1E@sourceware.org> Date: Mon, 27 Feb 2023 01:07:24 +0000 (GMT) List-Id: https://gcc.gnu.org/g:529e03b9882fe48cfa3c182abb12a5858a5762a2 commit r13-6353-g529e03b9882fe48cfa3c182abb12a5858a5762a2 Author: Lulu Cheng Date: Mon Feb 20 16:47:11 2023 +0800 LoongArch: Change the value of macro TRY_EMPTY_VM_SPACE from 0x8000000000 to 0x1000000000. The PCH mechanism first tries to map the .gch file to the virtual memory space pointed to by TRY_EMPTY_VM_SPACE during the compilation process. The original value of TRY_EMPTY_VM_SPACE macro is 0x8000000000, but like la464 only has 40 bits of virtual address space, this value just exceeds the address range. If we want to support chips with less than 40 bits virtual addresses, then the value of this macro needs to be set small. I think setting this value small will increase the probability of virtual address mapping failure. And the purpose of pch is to make compilation faster, but I think we rarely compile on embedded systems. So this situation may not be within our consideration. So change the value of this macro to 0x1000000000. gcc/ChangeLog: * config/host-linux.cc (TRY_EMPTY_VM_SPACE): Modify the value of the macro to 0x1000000000. Diff: --- gcc/config/host-linux.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/config/host-linux.cc b/gcc/config/host-linux.cc index a891651a7b6..d1aa7ab28ca 100644 --- a/gcc/config/host-linux.cc +++ b/gcc/config/host-linux.cc @@ -99,7 +99,7 @@ #elif defined(__riscv) && defined (__LP64__) # define TRY_EMPTY_VM_SPACE 0x1000000000 #elif defined(__loongarch__) && defined(__LP64__) -# define TRY_EMPTY_VM_SPACE 0x8000000000 +# define TRY_EMPTY_VM_SPACE 0x1000000000 #else # define TRY_EMPTY_VM_SPACE 0 #endif