I read that LDT (Local Descriptor Table) does not exist in 64-bit architecture and was wondering how a 32-bit system that uses it is emulated.
If LDT does not exist in 64-bit architecture how are 32-bit systems that use it emulated on a 64-bit architecture?
502 Views Asked by Kamil Abdurahim At
1
There are 1 best solutions below
Related Questions in ASSEMBLY
- (x64 Nasm) Writeline function on Linux
- Is the compiler Xcode uses to produce Assembly code a bad compiler?
- Why do we need AX instead of MOV DS, data directly with a segment?
- Bootloader in Assembly with Linux kernel
- How should the byte sequence 0x40 0x55 be interpreted by an x86-64 emulator?
- C++ code into assembly
- Drawing circles of increasing radius
- Assembly print on screen using pop ecx
- Equivalent to asm volatile in Gfortran?
- Show 640x480 BMP image with inline ASM c++
- Keep track of numbers entered in by a user in assembly
- 8086 Assembly Arrays with I/O
- DB ASM variable in Inline ASM C++
- What does Jump to means in callgrind?
- How to convert binary into decimal in assembly x8086?
Related Questions in X86
- Why do we need AX instead of MOV DS, data directly with a segment?
- Drawing circles of increasing radius
- Assembly print on screen using pop ecx
- How to add values from vector to each other
- Intel x64 instructions CMPSB/CMPSW/CMPSD/CMPSQ
- Compact implementation of logical AND in x86 assembly
- Can feenableexcept hurt a program performance?
- How do I display the result and remainder in ax and dx in Assembly (tasm)
- ASM : Trouble using int21h on real machine
- jmp instruction *%eax
- What steps are needed to load a second stage bootloader by name on a FAT32 file system in x86 Assembly?
- Assembly code to print a new line string
- Write System Call Argument Registers
- How to jump to an address saved in a register in intel assembly?
- Find middle value of a list
Related Questions in X86-64
- How should the byte sequence 0x40 0x55 be interpreted by an x86-64 emulator?
- os kern error : "ld: symbol(s) not found for architecture x86_64"
- Can feenableexcept hurt a program performance?
- MASM console window creation troubles (maybe my stack frame??)
- Bomb lab phase 5
- Displaying symbolic constants in Assembly Language
- puts implementation in assembly with nasm x86-64
- Can I use the mid bits on pointers (on 64-bit machines) to implement things (like tagged pointers)?
- Segmentation fault when exploit string overwrites the return pointer with the starting address on stack
- Reserve bytes in stack: x86 Assembly (64 bit)
- Assembly: why some x86 opcodes are invalid in x64?
- Clang runtime fault when throwing aligned type. Compiler bug?
- What fpu_xrstor_checking does? extra commentary?
- NASM: copying a pointer from a register to a buffer in .data
- Using an x64 assembler to reference memory
Related Questions in INSTRUCTION-SET
- Real-world analog to TIS-100
- What is the simplest Turing complete CPU instruction set which can execute code from ROM?
- How can I get the number of instructions executed by a program?
- Can't Compile for MIPS or ATOM with gcc
- Factors in designing Instruction set Arcitecture
- Transpiling to C vs C++ : range of CPU instructions
- Instruction execution latencies for A53
- Understanding FMA instructions performance
- Questions about adding jal instruction to mips single cycle datapath
- opcode of transfer from memory to register
- Instruction Encoding relating to MARIE Assembly language
- What instruction set does the Nvidia GeForce 6xx Series use?
- Clang vs gcc floating point performance on ARM
- MSP430 SWAP bytes explanation assembly
- Where is an ISA stored and how exactly is it taken into account?
Related Questions in GDT
- Constant reboot after setting up the Global Descriptor Table and protected mode
- Linear addressing and the GDT
- What happens if a process calls out to code belonging to another process?
- How can I initialise the GDT?
- I failed in switching the cpu from real-mode to protected-mode
- Why loading GDT in the following way works
- Boot sector stuck in "Booting from hard disk" loop in Qemu after switching to 32bit protected mode
- custom OS chrashes while loading GDT
- Rust gnu-asm, far jump in real mode
- Implementing User Mode and Kernel Mode Switching in 64 bit UEFI OS
- Why in xv6 there's sizeof(gdt)-1 in gdtdesc
- GDT segment reload failed
- If LDT does not exist in 64-bit architecture how are 32-bit systems that use it emulated on a 64-bit architecture?
- How to update GDT entries after initial loading?
- What does the "D" stand for in 386's "D bit"?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Your premise is incorrect. Even when running a 64-bit kernel, x86-64 can still use an LDT.
lldtis valid in 64-bit mode. More specifically, a comment on Is an LDT needed? indicates that 64-bit Windows forbids using it, but that's just Windows, not the x86-64 ISA. For example, x86-64 Linux still supports themodify_ldt()system call. (IIRC, Linux didn't bother to add functionality to let you create 64-bit code segments with it, though. But a purely 32-bit process wouldn't need to do that.)But that would only be relevant for a 32-bit user-space process that needs to create an LDT entry.
You were asking about a 32-bit system, i.e. booting an old kernel that isn't aware of x86-64 at all.
An x86-64 CPU in legacy mode (i.e. running a 32-bit kernel) is exactly identical to a CPU that doesn't support 64-bit mode at all. (Except that it will switch into 64-bit mode if you put certain bits in the right places.) So the CPU being 64-bit capable really has nothing to do with running a fully 32-bit system.
If you truly mean emulated, then the underlying HW is irrelevant. Write your emulator in any Turing-complete language, and include that feature. (Or use an existing one like BOCHS or Qemu.)
If you mean hardware virtualization (e.g. Intel VT or AMD-V), then a VM guest can do whatever it wants, including run in legacy mode and boot 32-bit Windows or run your own custom bare-metal OS in real, protected, or long mode. It's irrelevant if the host VM is running 64-bit Windows or whatever, the guest's LDT is its own business and doesn't involve an LDT on the host.
If you meant virtualization without hardware support, like in the bad old days before Intel VT and AMD-V, that's harder but the hypervisor is outside any of the guests, so they're still independent of each other. It's hard because x86 has some "sensitive" (in the virtualization sense) instructions that don't trap. This is why most people only do x86 virtualization at all with HW support. If that's not available, just emulate, like with BOCHS, or Qemu's JIT dynamic recompilation.