* Added ikrt_fl_log and ikrt_fx_log to the vm.

This commit is contained in:
Abdulaziz Ghuloum 2007-06-09 03:08:36 +03:00
parent 6712e9490b
commit 57f4d16ee2
2 changed files with 19 additions and 0 deletions

Binary file not shown.

View File

@ -80,6 +80,14 @@ ikrt_fl_sqrt(ikp x, ikpcb* pcb){
return r;
}
ikp
ikrt_fl_log(ikp x, ikpcb* pcb){
ikp r = ik_alloc(pcb, flonum_size) + vector_tag;
ref(r, -vector_tag) = (ikp)flonum_tag;
flonum_data(r) = log(flonum_data(x));
return r;
}
@ -127,6 +135,17 @@ ikrt_fx_atan(ikp x, ikpcb* pcb){
return r;
}
ikp
ikrt_fx_log(ikp x, ikpcb* pcb){
ikp r = ik_alloc(pcb, flonum_size) + vector_tag;
ref(r, -vector_tag) = (ikp)flonum_tag;
flonum_data(r) = log(unfix(x));
return r;
}
ikp
ikrt_flonum_to_bytevector(ikp x, ikp bv, ikpcb* pcb){
if(tagof(x) == vector_tag){