<link, Wiki: Execute>
xp->experienceworldborderwarningtime<time>
distance<distance>
set<distance>[time]
This file contains hidden or 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
| const int length = 1000; | |
| // create a module | |
| var module = LLVM.ModuleCreateWithName("Example"); | |
| // signature | |
| var funcType = LLVM.FunctionType(LLVM.ArrayType(LLVM.Int64Type(), length), new LLVMTypeRef[] { LLVM.ArrayType(LLVM.Int32Type(), length), LLVM.Int32Type() }, false); | |
| // actual definition | |
| var funcDef = LLVM.AddFunction(module, "Add", funcType); | |
| // builder |
This file contains hidden or 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 Targets | |
| LLVM.InitializeX86TargetMC(); | |
| LLVM.InitializeX86Target(); | |
| LLVM.InitializeX86TargetInfo(); | |
| LLVM.InitializeX86AsmParser(); | |
| LLVM.InitializeX86AsmPrinter(); | |
| const int length = 1000; | |
| // create a module |
This file contains hidden or 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 Targets | |
| LLVM.InitializeX86TargetMC(); | |
| LLVM.InitializeX86Target(); | |
| LLVM.InitializeX86TargetInfo(); | |
| LLVM.InitializeX86AsmParser(); | |
| LLVM.InitializeX86AsmPrinter(); | |
| // create a module | |
| var module = LLVM.ModuleCreateWithName("Example"); |
; MinecraftNetworkBenchmarks.ReadLongBenchmark.ReadLongPooledSync()
mov rcx,qword ptr [rcx+8]
call MinecraftNetworkBenchmarks.FullSyncDevNetworkUtils.ReadLong(System.IO.Stream)
nop
; Total bytes of code 10; MinecraftNetworkBenchmarks.FullSyncDevNetworkUtils.ReadLong(System.IO.Stream)
This file contains hidden or 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
| public class DebugRenderer : MonoBehaviour | |
| { | |
| private bool _enabled = true; | |
| static Material lineMaterial; | |
| static void CreateLineMaterial() | |
| { | |
| if (!lineMaterial) | |
| { | |
| // Unity has a built-in shader that is useful for drawing |
This file contains hidden or 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
| using System; | |
| using System.Collections.Generic; | |
| using System.Runtime.CompilerServices; | |
| using System.Text; | |
| namespace WorldStructure | |
| { | |
| public struct Chunk | |
| { | |
| public const int WIDTH = 16; |
This file contains hidden or 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
| using BenchmarkDotNet.Attributes; | |
| using BenchmarkDotNet.Order; | |
| using BenchmarkDotNet.Running; | |
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Numerics; | |
| using System.Runtime.Intrinsics; | |
| using System.Runtime.Intrinsics.X86; |
This file contains hidden or 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
| 9aed4553dba72f8424da7b3b3029e3974a5bea7b |