summaryrefslogtreecommitdiff
path: root/cryptlib.vcxproj
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2019-08-06 21:01:22 -0400
committerGitHub <noreply@github.com>2019-08-06 21:01:22 -0400
commitb1c691b53a4c4cf8a49b26c0a34bfea26c5b5884 (patch)
treebb6490ae1ac9e2c9121b5bfa937d14bb1e912819 /cryptlib.vcxproj
parente5ab7919f98326504629264253eb3ad68c0f3515 (diff)
downloadcryptopp-git-b1c691b53a4c4cf8a49b26c0a34bfea26c5b5884.tar.gz
Fix RDSEED hang on x86 (GH #872) (#873)
Calls to `MASM_RDSEED_GenerateBlock` would hang for an unknown reasons on Windows 10 and VS2017/VS2019 toolchains. Similar calls to `MASM_RDRAND_GenerateBlock` worked as expected. They were effectively the same code. The only differences were the function names and the opcodes (they were literally copy/paste). Splitting `rdrand.asm` (with both `RDRAND` and `RDSEED`) into `rdrand.asm` (with `RDRAND`) and `rdseed.asm` (with `RDSEED`) resolved the issue. We don't know why.
Diffstat (limited to 'cryptlib.vcxproj')
-rw-r--r--cryptlib.vcxproj10
1 files changed, 10 insertions, 0 deletions
diff --git a/cryptlib.vcxproj b/cryptlib.vcxproj
index 4985c096..fbafa9e8 100644
--- a/cryptlib.vcxproj
+++ b/cryptlib.vcxproj
@@ -373,6 +373,16 @@
<Command>ml64.exe /c /nologo /D_M_X64 /W3 /Cx /Zi /Fo"$(IntDir)rdrand-x64.obj" "%(FullPath)"</Command>
<Outputs>$(IntDir)\rdrand-x64.obj;%(Outputs)</Outputs>
</CustomBuild>
+ <CustomBuild Condition="'$(Platform)'=='Win32'" Include="rdseed.asm">
+ <Message>Building and assembling rdseed.asm</Message>
+ <Command>ml.exe /c /nologo /D_M_X86 /W3 /Cx /Zi /safeseh /Fo"$(IntDir)rdseed-x86.obj" "%(FullPath)"</Command>
+ <Outputs>$(IntDir)\rdseed-x86.obj;%(Outputs)</Outputs>
+ </CustomBuild>
+ <CustomBuild Condition="'$(Platform)'=='x64'" Include="rdseed.asm">
+ <Message>Building and assembling rdseed.asm</Message>
+ <Command>ml64.exe /c /nologo /D_M_X64 /W3 /Cx /Zi /Fo"$(IntDir)rdseed-x64.obj" "%(FullPath)"</Command>
+ <Outputs>$(IntDir)\rdseed-x64.obj;%(Outputs)</Outputs>
+ </CustomBuild>
<CustomBuild Condition="'$(Platform)'=='x64' AND ('$(Configuration)'=='Debug' Or '$(Configuration)'=='Release')" Include="x64dll.asm">
<Message>Building and assembling x64dll.asm</Message>
<Command>ml64.exe /c /nologo /D_M_X64 /W3 /Zi /Fo"$(IntDir)x64dll.obj" "%(FullPath)"</Command>