search for: stackbase

Displaying 11 results from an estimated 11 matches for "stackbase".

2013 Jul 25
4
[LLVMdev] Proposing a new 'alloca' parameter attribute to implement the Microsoft C++ ABI
...ns, while the callee may have called destructors on its arguments, the allocas can be considered live until the stack restore. Example ------- A single call to foo, assuming it is stdcall, would be lowered something like: %res = alloca %struct.A %base = llvm.stacksave() %arg1 = alloca %struct.A, stackbase %base %arg2 = alloca %struct.A, stackbase %base call @A_ctor(%arg1) call @A_ctor(%arg2) call x86_stdcallcc @foo(%res sret, %arg1 alloca, %arg2 alloca), stackrestore %base If control does not flow through a call or invoke with a stackrestore field, then manual calls to llvm.stackrestore must be emi...
2013 Oct 22
1
[LLVMdev] Starting implementation of 'inalloca' parameter attribute for MS C++ ABI pass-by-value
...ntion that I'm planning to start writing and sending out patches for this. Naming the attribute 'alloca' was really confusing, so I'd like to change it to 'inalloca', which follows the preposition pattern of inreg and byval. After discussion, we decided it was silly to add stackbase uses to alloca instructions. They should stay simple. Instead, we'll clarify that it is illegal for an optimization to raise an alloca used as an inalloca argument across a stacksave, and fix any transforms that do this. In particular, I'll look at the inliner, which is the most likely t...
2013 Jul 30
0
[LLVMdev] Proposing a new 'alloca' parameter attribute to implement the Microsoft C++ ABI
...rguments, the allocas can be considered live until the > stack > restore. > > Example > ------- > > A single call to foo, assuming it is stdcall, would be lowered something > like: > > %res = alloca %struct.A > %base = llvm.stacksave() > %arg1 = alloca %struct.A, stackbase %base > %arg2 = alloca %struct.A, stackbase %base > call @A_ctor(%arg1) > call @A_ctor(%arg2) > call x86_stdcallcc @foo(%res sret, %arg1 alloca, %arg2 alloca), stackrestore > %base > > If control does not flow through a call or invoke with a stackrestore field, > then manual...
2008 Nov 21
1
[LLVMdev] Simple stack machine
...for this (possibly very much tuned to LLVM). Of course, that would also mean building an LLVM backend. I guess having a very simple backend would also server LLVM well, as an example backend and one to base new architectures on. Now, on to my real question. Is there any LLVM backend for a (simple) stackbased machine? Anyone working on something like this? Anything we can use (either directly, or as an example and/or to get an idea how much work would be involved)? Gr. Matthijs -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-sign...
2013 Jul 30
1
[LLVMdev] Proposing a new 'alloca' parameter attribute to implement the Microsoft C++ ABI
...he ABI, and alloca pointer will be resolved to point to the appropriate outgoing argument slot. The verifier will be changed to reject IR with a live alloca between a call site with an alloca-attributed argument and the creation of that alloca. This will work however: %s1 = stacksave %1 = alloca stackbase %s1 %s2 = stacksave %2 = alloca stackbase %s2 call @foo(%2 alloca) stackrestore %s2 call @foo(%1 alloca) stackrestore %s1 Because the %2 alloca is dead due to the stack restore before the second foo call. I should also mention how this interacts with regparms. The win64 CC has 4 regparms, and i...
2013 Jul 29
0
[LLVMdev] Proposing a new 'alloca' parameter attribute to implement the Microsoft C++ ABI
...s on its arguments, the allocas can be considered live until the stack > restore. > > Example > ------- > > A single call to foo, assuming it is stdcall, would be lowered something like: > > %res = alloca %struct.A > %base = llvm.stacksave() > %arg1 = alloca %struct.A, stackbase %base > %arg2 = alloca %struct.A, stackbase %base > call @A_ctor(%arg1) > call @A_ctor(%arg2) > call x86_stdcallcc @foo(%res sret, %arg1 alloca, %arg2 alloca), stackrestore %base > > If control does not flow through a call or invoke with a stackrestore field, > then manual call...
2020 Mar 28
0
[klibc:update-dash] dash: memalloc: Avoid looping in growstackto
...min) { size_t newlen; newlen = stacknleft * 2; if (newlen < stacknleft) sh_error("Out of space"); - if (newlen < 128) - newlen += 128; + min = SHELL_ALIGN(min | 128); + if (newlen < min) + newlen += min; if (stacknxt == stackp->space && stackp != &stackbase) { struct stack_block *sp; @@ -261,15 +261,15 @@ void * growstackstr(void) { size_t len = stackblocksize(); - growstackblock(); + + growstackblock(0); return stackblock() + len; } char *growstackto(size_t len) { - while (stackblocksize() < len) - growstackblock(); - + if (stackblo...
2011 Nov 30
1
[PATCH] [MEMALLOC] remove unused variable
...nged, 0 insertions(+), 2 deletions(-) diff --git a/usr/dash/memalloc.c b/usr/dash/memalloc.c index e75e609..406d0c8 100644 --- a/usr/dash/memalloc.c +++ b/usr/dash/memalloc.c @@ -213,13 +213,11 @@ growstackblock(void) newlen += 128; if (stacknxt == stackp->space && stackp != &stackbase) { - struct stack_block *oldstackp; struct stack_block *sp; struct stack_block *prevstackp; size_t grosslen; INTOFF; - oldstackp = stackp; sp = stackp; prevstackp = sp->prev; grosslen = newlen + sizeof(struct stack_block) - MINSIZE; -- 1.7.3.1
2012 Jul 02
0
[klibc:master] [MEMALLOC] Avoid gcc warning: variable ' oldstackp' set but not used
...lloc.c @@ -206,20 +206,18 @@ growstackblock(void) { size_t newlen; - newlen = stacknleft * 2; + newlen = stacknleft * 2; if (newlen < stacknleft) sh_error("Out of space"); if (newlen < 128) newlen += 128; if (stacknxt == stackp->space && stackp != &stackbase) { - struct stack_block *oldstackp; struct stack_block *sp; struct stack_block *prevstackp; size_t grosslen; INTOFF; - oldstackp = stackp; sp = stackp; prevstackp = sp->prev; grosslen = newlen + sizeof(struct stack_block) - MINSIZE;
2018 May 11
0
Wine release 3.8
...Installation of '.NET documentation' from Windows SDK for Windows 7 and .NET Framework 3.5 SP1 installer fails (VS90-KB953196-x86.exe hotfix fails with incorrect TARGETDIR) 23757 Free Pascal 2.4.0 segfaults (Cygwin 1.5.18 TLS implementation overwrites Wine/glibc/pthread data near Tib->StackBase) 30449 GDIPaint does not paint (works with native gdiplus) 30713 Microsoft Visual C++ 64-bit redistributables get incorrectly installed into SysWOW64 (system directory for 32-bit files) when run under 64-bit Wine 31741 python.org 64-bit Python 2.7.3 installer: selecting preferred installat...
2013 Oct 26
2
[PATCH] 1. changes for vdiskadm on illumos based platform
...<< SPA_MINBLOCKSHIFT; int err = errnum; /* preserve previous errnum state */ + uint64_t sector; /* if it''s our first time here, zero the best uberblock out */ if (best_drive == 0 && best_part == 0 && find_best_root) { @@ -1296,7 +1553,7 @@ zfs_mount(void) stackbase = ZFS_SCRATCH; stack = stackbase; - ub_array = (uberblock_phys_t *)stack; + ub_array = stack; stack += VDEV_UBERBLOCK_RING; osp = (objset_phys_t *)stack; @@ -1305,8 +1562,6 @@ zfs_mount(void) for (label = 0; label < VDEV_LABELS; label++) { - uint64_t sector; - /* * some elt...