added gdt_set_gate() function