Skip to content

Commit ccd1bcf

Browse files
committed
Make tydesc glue functions use cdecl.
1 parent 5378f48 commit ccd1bcf

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

src/comp/middle/trans.rs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1971,7 +1971,7 @@ fn declare_generic_glue(&@local_ctxt cx,
19711971
fn_nm = mangle_internal_name_by_seq(cx.ccx,
19721972
"glue_" + name);
19731973
}
1974-
auto llfn = decl_fastcall_fn(cx.ccx.llmod, fn_nm, llfnty);
1974+
auto llfn = decl_cdecl_fn(cx.ccx.llmod, fn_nm, llfnty);
19751975
set_glue_inlining(cx, llfn, t);
19761976
ret llfn;
19771977
}
@@ -3232,11 +3232,11 @@ fn call_tydesc_glue_full(&@block_ctxt cx, ValueRef v,
32323232
auto llfnptr = cx.build.GEP(tydesc, [C_int(0), C_int(field)]);
32333233
auto llfn = cx.build.Load(llfnptr);
32343234

3235-
cx.build.FastCall(llfn, [C_null(T_ptr(T_nil())),
3236-
cx.fcx.lltaskptr,
3237-
C_null(T_ptr(T_nil())),
3238-
lltydescs,
3239-
llrawptr]);
3235+
cx.build.Call(llfn, [C_null(T_ptr(T_nil())),
3236+
cx.fcx.lltaskptr,
3237+
C_null(T_ptr(T_nil())),
3238+
lltydescs,
3239+
llrawptr]);
32403240
}
32413241

32423242
fn call_tydesc_glue(&@block_ctxt cx, ValueRef v,
@@ -3311,7 +3311,7 @@ fn call_cmp_glue(&@block_ctxt cx,
33113311
llrawrhsptr,
33123312
llop];
33133313

3314-
r.bcx.build.FastCall(llfn, llargs);
3314+
r.bcx.build.Call(llfn, llargs);
33153315

33163316
ret res(r.bcx, r.bcx.build.Load(llcmpresultptr));
33173317
}

src/rt/rust_internal.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -206,11 +206,11 @@ struct rust_timer {
206206

207207
#include "rust_util.h"
208208

209-
typedef void FASTCALL (glue_fn)(void *, rust_task *, void *,
210-
const type_desc **, void *);
211-
typedef void FASTCALL (cmp_glue_fn)(void *, rust_task *, void *,
212-
const type_desc **,
213-
void *, void *, int8_t);
209+
typedef void CDECL (glue_fn)(void *, rust_task *, void *,
210+
const type_desc **, void *);
211+
typedef void CDECL (cmp_glue_fn)(void *, rust_task *, void *,
212+
const type_desc **,
213+
void *, void *, int8_t);
214214

215215

216216
struct type_desc {

0 commit comments

Comments
 (0)