This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "runtime.h" | |
// Typeid redirect table | |
static unsigned __nullcTR[170]; | |
// Function pointer table | |
static __nullcFunctionArray* __nullcFM; | |
// Function pointer redirect table | |
static unsigned __nullcFR[183]; | |
// Type prototypes | |
struct auto_ref; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void FillCallStructType(DCstruct *&callType, FastVector<ExternTypeInfo> &typeInfo, FastVector<ExternMemberInfo> &memberInfo, ExternTypeInfo &type, unsigned count) | |
{ | |
switch(type.subCat) | |
{ | |
case ExternTypeInfo::CAT_NONE: | |
assert(callType); | |
switch(type.type) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct LLVMContextRefOpaque{}; | |
struct LLVMModuleRefOpaque{}; | |
struct LLVMBuilderRefOpaque{}; | |
struct LLVMPassManagerRefOpaque{}; | |
struct LLVMTypeRefOpaque{}; | |
struct LLVMValueRefOpaque{}; | |
struct LLVMBasicBlockRefOpaque{}; | |
typedef LLVMContextRefOpaque* LLVMContextRef; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define SHORT(X) typedef NullcCallBaseType<X>::type X##u; const unsigned X##s = NullcCallBaseType<X>::size | |
#define SHORTS_0 (void)argBuf | |
#define SHORTS_1 SHORT(A1) | |
#define SHORTS_2 SHORTS_1; SHORT(A2) | |
#define SHORTS_3 SHORTS_2; SHORT(A3) | |
#define SHORTS_4 SHORTS_3; SHORT(A4) | |
#define SHORTS_5 SHORTS_4; SHORT(A5) | |
#define SHORTS_6 SHORTS_5; SHORT(A6) | |
#define SHORTS_7 SHORTS_6; SHORT(A7) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
__declspec(naked) void* self() | |
{ | |
__asm mov eax, [esp] | |
__asm ret | |
} | |
int test() | |
{ | |
DWORD unused = 0; | |
VirtualProtect(self(), 4096, PAGE_EXECUTE_READWRITE, &unused); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import std.io; | |
import std.math; | |
import std.time; | |
double PI = 3.141592653589793; | |
double SOLAR_MASS = 4 * PI * PI; | |
double DAYS_PER_YEAR = 365.24; | |
class Body { | |
double x, y, z, vx, vy, vz, mass; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma once | |
#include <assert.h> | |
#include "Output.h" | |
namespace NULLCTime | |
{ | |
void clockMicroInit(); | |
unsigned clockMicro(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void TestEncoding() | |
{ | |
TestRptrXmmEncoding(x86MOVSS); | |
TestXmmXmmEncoding(x86MOVSD); | |
TestRptrXmmEncoding(x86MOVSD); | |
TestXmmRptrEncoding(x86MOVSD); | |
TestRegXmmEncoding(x86MOVD); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; ------------------- Invalidation ---------------- | |
0xc000156f: ; 5487 | |
; 5487: less r9, r8, r6 | |
mov eax, dword [rbx+64] | |
cmp eax, dword [rbx+48] | |
; 5488: jmpz r9, 5541 // kill late[r9] | |
jge '0xc00015a5' | |
// auto bi = this.bodies[i]; | |
; 5489: loadq r9, [r4 + 0] | |
mov rax, qword [rbx+32] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
0xc000156f: | |
mov eax, dword [rbx+64] | |
cmp eax, dword [rbx+48] | |
jge '0xc00015a5' | |
mov rax, qword [rbx+32] | |
mov rax, qword [rax] | |
mov rdx, qword [rbx+32] | |
mov edx, dword [rdx+8] | |
mov edi, dword [rbx+56] | |
cmp edi, edx |
OlderNewer