Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 14 additions & 8 deletions Core/Libraries/Source/WWVegas/WWDebug/wwmemlog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -316,18 +316,24 @@ WWINLINE void Lock_Mem_Log_Mutex()
#define ts_lock _emit 0xF0
assert(((unsigned)&nFlag % 4) == 0);

__asm mov ebx, [nFlag]
__asm ts_lock
__asm bts dword ptr [ebx], 0
__asm jc The_Bit_Was_Previously_Set_So_Try_Again
__asm
{
mov ebx, [nFlag]
ts_lock
bts dword ptr [ebx], 0
jc The_Bit_Was_Previously_Set_So_Try_Again
}
return;

The_Bit_Was_Previously_Set_So_Try_Again:
ThreadClass::Switch_Thread();
__asm mov ebx, [nFlag]
__asm ts_lock
__asm bts dword ptr [ebx], 0
__asm jc The_Bit_Was_Previously_Set_So_Try_Again
__asm
{
mov ebx, [nFlag]
ts_lock
bts dword ptr [ebx], 0
jc The_Bit_Was_Previously_Set_So_Try_Again
}

#endif
}
Expand Down
22 changes: 14 additions & 8 deletions Core/Libraries/Source/WWVegas/WWLib/mutex.h
Original file line number Diff line number Diff line change
Expand Up @@ -160,19 +160,25 @@ class FastCriticalSectionClass
// ASM statements because sometimes the jump
// would be 1 byte off....

__asm mov ebx, [nFlag]
__asm ts_lock
__asm bts dword ptr [ebx], 0
__asm jnc BitSet
__asm
{
mov ebx, [nFlag]
ts_lock
bts dword ptr [ebx], 0
jnc BitSet
}
//__asm _emit 0x73
//__asm _emit 0x0f

The_Bit_Was_Previously_Set_So_Try_Again:
ThreadClass::Switch_Thread();
__asm mov ebx, [nFlag]
__asm ts_lock
__asm bts dword ptr [ebx], 0
__asm jc The_Bit_Was_Previously_Set_So_Try_Again
__asm
{
mov ebx, [nFlag]
ts_lock
bts dword ptr [ebx], 0
jc The_Bit_Was_Previously_Set_So_Try_Again
}
//_asm _emit 0x72
//_asm _emit 0xf1

Expand Down
10 changes: 8 additions & 2 deletions Core/Libraries/Source/debug/debug_debug.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@
void Debug::InstallExceptionHandler()
{
#if defined(_MSC_VER)
_set_se_translator(LocalSETranslator);

Check warning on line 291 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build Generals / win32-vcpkg-profile+t+e

calling _set_se_translator() requires /EHa

Check warning on line 291 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build Generals / win32-vcpkg-debug+t+e

calling _set_se_translator() requires /EHa

Check warning on line 291 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build GeneralsMD / win32-vcpkg-debug+t+e

calling _set_se_translator() requires /EHa

Check warning on line 291 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build Generals / win32-vcpkg+t+e

calling _set_se_translator() requires /EHa

Check warning on line 291 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build GeneralsMD / win32-vcpkg+t+e

calling _set_se_translator() requires /EHa

Check warning on line 291 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build GeneralsMD / win32-vcpkg-profile+t+e

calling _set_se_translator() requires /EHa
#elif defined(__GNUC__) && defined(_WIN32)
// MinGW-w64 doesn't support _set_se_translator, use Vectored Exception Handler
AddVectoredExceptionHandler(1, LocalVectoredExceptionHandler);
Expand Down Expand Up @@ -436,7 +436,10 @@
break;
case IDRETRY:
#if defined(_MSC_VER)
_asm int 0x03
_asm
{
int 0x03
}
#elif defined(__GNUC__)
__builtin_trap();
#else
Expand Down Expand Up @@ -710,7 +713,10 @@
break;
case IDRETRY:
#if defined(_MSC_VER)
_asm int 0x03
_asm
{
int 0x03
}
#elif defined(__GNUC__)
__builtin_trap();
#else
Expand Down Expand Up @@ -774,9 +780,9 @@
unsigned len=strlen(str);

// forced width?
if (len<m_width)

Check warning on line 783 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build Generals / win32-vcpkg-profile+t+e

'<': signed/unsigned mismatch

Check warning on line 783 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build Generals / win32-vcpkg-debug+t+e

'<': signed/unsigned mismatch

Check warning on line 783 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build GeneralsMD / win32-vcpkg-debug+t+e

'<': signed/unsigned mismatch

Check warning on line 783 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build Generals / win32-vcpkg+t+e

'<': signed/unsigned mismatch

Check warning on line 783 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build GeneralsMD / win32-vcpkg+t+e

'<': signed/unsigned mismatch

Check warning on line 783 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build GeneralsMD / win32-vcpkg-profile+t+e

'<': signed/unsigned mismatch
{
for (unsigned k=len;k<m_width;k++)

Check warning on line 785 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build Generals / win32-vcpkg-profile+t+e

'<': signed/unsigned mismatch

Check warning on line 785 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build Generals / win32-vcpkg-debug+t+e

'<': signed/unsigned mismatch

Check warning on line 785 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build GeneralsMD / win32-vcpkg-debug+t+e

'<': signed/unsigned mismatch

Check warning on line 785 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build Generals / win32-vcpkg+t+e

'<': signed/unsigned mismatch

Check warning on line 785 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build GeneralsMD / win32-vcpkg+t+e

'<': signed/unsigned mismatch

Check warning on line 785 in Core/Libraries/Source/debug/debug_debug.cpp

View workflow job for this annotation

GitHub Actions / Build GeneralsMD / win32-vcpkg-profile+t+e

'<': signed/unsigned mismatch
AddOutput(&m_fillChar,1);
}

Expand Down
14 changes: 10 additions & 4 deletions Core/Tools/WW3D/pluglib/wwmath.h
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,11 @@ inline long WWMath::Float_To_Long (float f)
{
#if defined(_MSC_VER) && defined(_M_IX86)
long retval;
__asm fld dword ptr [f]
__asm fistp dword ptr [retval]
__asm
{
fld dword ptr [f]
fistp dword ptr [retval]
}
return retval;
#else
return (long) f;
Expand All @@ -217,8 +220,11 @@ inline long WWMath::Float_To_Long (double f)
{
#if defined(_MSC_VER) && defined(_M_IX86)
long retval;
__asm fld qword ptr [f]
__asm fistp dword ptr [retval]
__asm
{
fld qword ptr [f]
fistp dword ptr [retval]
}
return retval;
#else
return (long) f;
Expand Down
Loading