Path: ...!weretis.net!feeder9.news.weretis.net!news.nk.ca!rocksolid2!i2pn2.org!.POSTED!not-for-mail From: mitchalsup@aol.com (MitchAlsup1) Newsgroups: comp.arch Subject: Re: Segments Date: Tue, 7 Jan 2025 20:16:57 +0000 Organization: Rocksolid Light Message-ID: <18cc69cf39bb7b0df7fc8733f9ccaab6@www.novabbs.org> References: <2024Oct6.150415@mips.complang.tuwien.ac.at> <2025Jan3.093849@mips.complang.tuwien.ac.at> <2025Jan5.121028@mips.complang.tuwien.ac.at> <2025Jan6.092443@mips.complang.tuwien.ac.at> <20250107170429.00003de2@yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: i2pn2.org; logging-data="2501726"; mail-complaints-to="usenet@i2pn2.org"; posting-account="o5SwNDfMfYu6Mv4wwLiW6e/jbA93UAdzFodw5PEa6eU"; User-Agent: Rocksolid Light X-Spam-Checker-Version: SpamAssassin 4.0.0 X-Rslight-Posting-User: cb29269328a20fe5719ed6a1c397e21f651bda71 X-Rslight-Site: $2y$10$PWe2/SxqeFRfSCgrFjzjGOUykSnV9et17X33Gd52oT1k0AG6IAqGa Bytes: 3047 Lines: 45 On Tue, 7 Jan 2025 15:04:29 +0000, Michael S wrote: > On Tue, 07 Jan 2025 14:43:02 GMT > scott@slp53.sl.home (Scott Lurndal) wrote: > >> Thomas Koenig writes: >>>Scott Lurndal schrieb: >>> >>>>>Assume a class of load and store instructions containing >>>>> >>>>>- One source or destination register >>>>>- One base register >>>>>- One index register >>>>>- One ubound register >>>> >>>> See aforementioned CHERI. >>> >>>CHERY targets C, which on the one hand, I understand (there's a >>>ton of C code out there), but trying to retrofit a safe memory >>>model onto C seems a bit awkward - it might have been better to >>>target a language which has arrays in the first place, unlike C. >>> >>>The floating point size is weird (and also does not catch all >>>errors, such as writing one element past a huge array). >>> >>>I haven't seen any consideration of how CHERI would integrate >>>with languages which have multidimensional arrays. How would >>> >>> do j=1,10 >>> do i=1,11 >>> a(i,j) = 42. >>> end do >>> end do >>> >>>interact with Cheri if a was a 10*10 array ? Would it be >>>necessary to create a capability for a(:,j)? >> >> A multidimensional array is a single contiguous >> blob of memory, the capability would encompass the >> entire region of memory containing the array. > > Then out of bound access like a(9,11) would not be caught. > I don't know if it has to be caught by Fortran rules. It is certainly > caught both in Matlab and in Octave. And Matlab has Fortran roots. WATFIV would catch a(9,11)