瀏覽代碼

* optimization in WebAssembly's MutexKind() function - mark the first parameter
as const, to avoid making a copy on the stack

Nikolay Nikolov 1 年之前
父節點
當前提交
8413c2b073
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      rtl/wasi/wasmmutex.inc

+ 1 - 1
rtl/wasi/wasmmutex.inc

@@ -8,7 +8,7 @@ Type
   TMutexKind = (mkNormal,mkRecursive);
   TMutexKind = (mkNormal,mkRecursive);
   TLockMutexResult = (lmrNone,lmrOK,lmrNotOwner,lmrError,lmrTimeout);
   TLockMutexResult = (lmrNone,lmrOK,lmrNotOwner,lmrError,lmrTimeout);
 
 
-Function MutexKind(M : TWasmMutex) : TMutexKind;
+Function MutexKind(const M : TWasmMutex) : TMutexKind;
 
 
 begin
 begin
   Result:=TMutexKind(M.Kind);
   Result:=TMutexKind(M.Kind);