C++ Logo

std-proposals

Advanced search

Re: [std-proposals] Make all data pointers intercompatible

From: organicoman <organicoman_at_[hidden]>
Date: Tue, 28 Jan 2025 17:28:44 +0100
I don't have enough data to backup your input.Yet, this thread is worth standardizing.And it tackles the same issue concerning the bits length used for virtual address space. (48bits instead of other value, would nice to standardize this value too)Sent from my Galaxy
-------- Original message --------From: Bo Persson via Std-Proposals <std-proposals_at_[hidden]> Date: 1/28/25 4:44 PM (GMT+01:00) To: std-proposals_at_[hidden] Cc: Bo Persson <bo_at_[hidden]> Subject: Re: [std-proposals] Make all data pointers intercompatible On 2025-01-28 at 15:08, organicoman via Std-Proposals wrote:> >Here's what I want:> > >Point 1) void* and char* are exactly the >same.> > At hardware level they are already the same, a different pointer size > is just a compiler concept, backed up by some bookkeeping.> void* has always the size of the CPU register, for efficiency, > configuring it to a smaller size is a compiler concept, that is, instead > of using the natural architecture instruction, the compiler issues a > smaller register instruction.> Expl: instead of> mov rax, [valueOf ptr] => mov eax, [valueOf ptr]>           ^^^ in 64bit Arch use a     ^^^ 32bit void*> Are we assuming x86 and Linux/Windows only?We have seen architectures with separate address registers, not of the same size as integer and floating-point registers.-- Std-Proposals mailing listStd-Proposals_at_[hidden]://lists.isocpp.org/mailman/listinfo.cgi/std-proposals

Received on 2025-01-28 16:28:53