简体   繁体   English

在Win 7 64bit下使用/ 3gb开关(-GF LARGEADDRESSAWARE)运行32bit Borland XE2应用程序?

[英]Running 32bit Borland XE2 app under Win 7 64bit with /3gb switch (-GF LARGEADDRESSAWARE )?

As the title states, I am running a 32 bit application under win 7 64 bit. 如标题所示,我正在win 7 64位下运行32位应用程序。 The application is made in C++ in Embarcadero XE2. 该应用程序是在Embarcadero XE2中以C ++编写的。 I need more than 2GB of memory. 我需要超过2GB的内存。

Steps: - I enabled the 3GB switch and I rebooted the pc. 步骤:-我启用了3GB开关,然后重新启动了PC。 - I tried adding -GF: LARGEADDRESSAWARE to project options/c++ linker/Output Flags but then linking failed. -我尝试将-GF:LARGEADDRESSAWARE添加到项目选项/ C ++链接器/输出标志,但是链接失败。 It said: "Failed command GF:" or something like that. 它说:“ GF命令失败:”或类似的内容。 I then found on a forum that you should do it manually in the .bpr file under FLAGS section. 然后,我在论坛上发现您应该在FLAGS部分下的.bpr文件中手动进行此操作。 I added the flag and then the project linked. 我添加了标志,然后将项目链接了。 However, my memory available indicator in the app tells me i'm still getting under 2 GB. 但是,应用程序中的可用内存指示器告诉我,我的内存仍不足2 GB。

Questions: 1. how to properly make this work ? 问题:1.如何正确进行这项工作? 2. how to tell if I got 3gb of memory or not? 2.如何判断我是否有3gb的内存?

Thank you in advance 先感谢您

The /3GB switch is for 32 bit systems only. /3GB开关仅适用于32位系统。 Your system is a 64 bit system. 您的系统是64位系统。 That means that a 32 bit executable with the LARGEADDRESSAWARE PE flag will have a 4GB address space. 这意味着带有LARGEADDRESSAWARE PE标志的32位可执行文件将具有4GB地址空间。 Don't attempt to use the /3GB boot option. 不要尝试使用/3GB引导选项。

You can check whether or not your executable has the LARGEADDRESSAWARE PE flag set by using any PE viewing tool. 您可以使用任何PE查看工具来检查可执行文件是否设置了LARGEADDRESSAWARE PE标志。 With the MS toolchain you would use dumpbin . 使用MS工具链,您将使用dumpbin The Embarcadero toolchain equivalent is tdump . Embarcadero工具链的等效项是tdump In addition, there are countless GUI PE viewers. 此外,还有无数的GUI PE查看器。 Find a tool that works and make sure that you have properly set this PE flag. 查找一个有效的工具,并确保已正确设置此PE标志。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在64位(或32位)Windows上以32位进程访问> 2,3,4GB文件 - Accessing >2,3,4GB Files in 32bit Process on 64bit (or 32bit) Windows 64位服务器下的OpenSSL问题,同一32位(QT应用程序)下没有 - OpenSSL issue under 64bit server and none under same 32bit (QT app) 检测Linux下的64位环境中是否运行32位进程 - Detect if a 32bit process is running in a 64bit environment under Linux 在64位和32位系统上运行程序 - Running a program on a 64bit and 32bit system 从32位应用启动64位应用? - Start a 64bit app from a 32bit app? Windows应用商店DLL 32位和64位 - Windows Store App DLL 32bit and 64bit Xcode:编译具有32bit库的64bit应用 - Xcode: compile 64bit app with 32bit library 运行msi会在32位win7中导致“模块注册失败”,但在64位win7中有效 - Running msi causes “module failed to register” in 32bit win7,but works in 64bit win7 在Win7 64bit上崩溃未处理的第一次机会异常(在XP 32bit,Linux 64bit上没有问题) - Crash over unhandled first chance exception on Win7 64bit (no issue on XP 32bit, Linux 64bit) C ++ Windows Shell扩展-Win7 32位-64位兼容性问题 - C++ Windows Shell Extensions - Win7 32bit - 64bit compatibility issues
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM