mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-05 07:08:48 +00:00
Correct weak handling
This commit is contained in:
@@ -1738,7 +1738,7 @@ lbValue lb_build_builtin_proc(lbProcedure *p, Ast *expr, TypeAndValue const &tv,
|
|||||||
}
|
}
|
||||||
|
|
||||||
// TODO(bill): Figure out how to make it weak
|
// TODO(bill): Figure out how to make it weak
|
||||||
LLVMBool single_threaded = weak;
|
LLVMBool single_threaded = false;
|
||||||
|
|
||||||
LLVMValueRef value = LLVMBuildAtomicCmpXchg(
|
LLVMValueRef value = LLVMBuildAtomicCmpXchg(
|
||||||
p->builder, address.value,
|
p->builder, address.value,
|
||||||
@@ -1747,6 +1747,7 @@ lbValue lb_build_builtin_proc(lbProcedure *p, Ast *expr, TypeAndValue const &tv,
|
|||||||
failure_ordering,
|
failure_ordering,
|
||||||
single_threaded
|
single_threaded
|
||||||
);
|
);
|
||||||
|
LLVMSetWeak(value, weak);
|
||||||
|
|
||||||
if (tv.type->kind == Type_Tuple) {
|
if (tv.type->kind == Type_Tuple) {
|
||||||
Type *fix_typed = alloc_type_tuple();
|
Type *fix_typed = alloc_type_tuple();
|
||||||
|
|||||||
Reference in New Issue
Block a user