Browse Source

Unify abi for wasm32 and the future wasm64

gingerBill 3 years ago
parent
commit
b57edb89eb
1 changed files with 2 additions and 7 deletions
  1. 2 7
      src/llvm_abi.cpp

+ 2 - 7
src/llvm_abi.cpp

@@ -1056,7 +1056,7 @@ namespace lbAbiArm64 {
 	}
 	}
 }
 }
 
 
-namespace lbAbiWasm32 {
+namespace lbAbiWasm {
 	/*
 	/*
 		NOTE(bill): All of this is custom since there is not an "official"
 		NOTE(bill): All of this is custom since there is not an "official"
 		            ABI definition for WASM, especially for Odin.
 		            ABI definition for WASM, especially for Odin.
@@ -1312,13 +1312,8 @@ LB_ABI_INFO(lb_get_abi_info) {
 	case TargetArch_arm64:
 	case TargetArch_arm64:
 		return lbAbiArm64::abi_info(c, arg_types, arg_count, return_type, return_is_defined, calling_convention);
 		return lbAbiArm64::abi_info(c, arg_types, arg_count, return_type, return_is_defined, calling_convention);
 	case TargetArch_wasm32:
 	case TargetArch_wasm32:
-		// TODO(bill): implement wasm32's ABI correct 
-		// NOTE(bill): this ABI is only an issue for WASI compatibility
-		return lbAbiWasm32::abi_info(c, arg_types, arg_count, return_type, return_is_defined, calling_convention);
 	case TargetArch_wasm64:
 	case TargetArch_wasm64:
-		// TODO(bill): implement wasm64's ABI correct 
-		// NOTE(bill): this ABI is only an issue for WASI compatibility
-		return lbAbiAmd64SysV::abi_info(c, arg_types, arg_count, return_type, return_is_defined, calling_convention);
+		return lbAbiWasm::abi_info(c, arg_types, arg_count, return_type, return_is_defined, calling_convention);
 	}
 	}
 
 
 	GB_PANIC("Unsupported ABI");
 	GB_PANIC("Unsupported ABI");