OpenGL rebuild project start!
This commit is contained in:
@@ -1,18 +1,26 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
|
||||
namespace StgSharp.Optimization
|
||||
{
|
||||
public static unsafe partial class SSE
|
||||
{
|
||||
[DllImport("Kernel32.dll", EntryPoint = "VirtualAlloc")]
|
||||
private static extern IntPtr VirtualAlloc(IntPtr address, int size, uint allocType, uint protect);
|
||||
[DllImport("Kernel32.dll", EntryPoint = "VirtualFree")]
|
||||
private static extern bool VirtualFree(IntPtr address, int size, uint freeType);
|
||||
|
||||
const uint MEM_COMMIT = 0x1000;
|
||||
const uint MEM_RESERVE = 0x2000;
|
||||
const uint PAGE_EXECUTE_READWRITE = 0x40;
|
||||
const uint MEM_RELEASE = 0x8000;
|
||||
|
||||
static SSE()
|
||||
{
|
||||
//编译模拟Sqrtss指令
|
||||
|
||||
var sqrtssCachePointer = stackalloc ulong[1];
|
||||
InitSqrtss();
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user