working on APIC code and malloc :)