similar to: [LLVMdev] LLVM and coroutines/microthreads

Displaying 20 results from an estimated 40000 matches similar to: "[LLVMdev] LLVM and coroutines/microthreads"

2009 Apr 16
0
[LLVMdev] LLVM and coroutines/microthreads
On Thu, Apr 16, 2009 at 9:47 AM, Jonathan D. Turner <jonathan.d.turner at gmail.com> wrote: > I saw this was mentioned briefly last year, but there seemed to be > some confusion as to what coroutines entailed and the thread died out. >  This technique has an unfortunate number of names, but it does get a > lot of use, including popular languages like Ruby. > > I'm
2009 Apr 16
1
[LLVMdev] LLVM and coroutines/microthreads
On Thu, Apr 16, 2009 at 3:21 PM, OvermindDL1 <overminddl1 at gmail.com> wrote: > > First, I will assume that you have read > http://www.nondot.org/sabre/LLVMNotes/ExplicitlyManagedStackFrames.txt > and if you have not, do so. I hadn't. That's very similar to what I had tried early on, but found it was actually slower than managing my own stacks lazily (on continuation,
2016 Jun 12
2
[RFC] LLVM Coroutines
(Dropped llvm-dev by accident. Putting it back) HI Eli: >> coro.barrier() doesn't work: if the address of the alloca doesn't escape, >> alias analysis will assume the barrier can't read or write the value of >> the alloca, so the barrier doesn't actually block code movement. Got it. I am new to this and learning a lot over the course of this thread. Thank you
2008 Sep 30
2
[LLVMdev] Integer handling
OvermindDL1 wrote: > > It is using the Actor-Oriented model, not Object-Oriented. > /* snip */ > By keeping the type system based on the actual types it allows > arbitrary message passing to any other actor without needing to load > any code relating to the actors, you can just send a structure with > the appropriate ID and format and it will 'just work' as the
2016 Jun 12
2
[RFC] LLVM Coroutines
I think I got it. Original model (with coro.fork and two-way coro.suspend) will work with a tiny tweak. In the original model, I was replacing coro.suspend with br %return in original function. The problem was coming from potential phi-nodes introduces into return block during optimizations. Let's make sure that there is only entry into the return block. In the original model, ReturnBB had
2011 Aug 04
0
[LLVMdev] [RFC] Coroutines
On 07/28/2011 05:31 PM, Sanjoy Das wrote: > Hi llvmdev! > > I've been working on adding coroutines to LLVM. Mentioned below is the > implementation plan I'm following, for suggestions, flames and other > input. Using segmented stacks is a prerequisite. I think my only comment is that, while this would probably work, implementing it in C with a bit of assembly for
2011 Jul 28
4
[LLVMdev] [RFC] Coroutines
Hi llvmdev! I've been working on adding coroutines to LLVM. Mentioned below is the implementation plan I'm following, for suggestions, flames and other input. Using segmented stacks is a prerequisite. The idea is to associate every coroutine with a coroutine descriptor. A coroutine descriptor consists of four words: w0, w1, w2 and w3. w0 always contains the _launcher_, and invoking a
2008 Nov 29
0
[LLVMdev] explicit stack management
William Morgan wrote: > Hi all, > > At the bottom of chapter 8 of the tutorial, on the topic of closures, > mentions that there are "often better ways to implement these features > than explicit stack frames". Does anyone know what techniques this > cryptic statement might be referring to? > > Thanks! > I would say it means to have a "stackless"
2008 Nov 29
3
[LLVMdev] explicit stack management
Hi all, At the bottom of chapter 8 of the tutorial, on the topic of closures, mentions that there are "often better ways to implement these features than explicit stack frames". Does anyone know what techniques this cryptic statement might be referring to? Thanks! -- William <wmorgan-llvm at masanjin.net>
2008 Sep 30
2
[LLVMdev] Integer handling
OvermindDL1 wrote: > > I know why it was removed, and it does make sense, just would be nice > if there was an option to be able to get two pointer to a specific > llvm::IntegerType, functionally they would be identical, but for user > code (hence, my code) would be useful as I could match it for the > different ones at generate different code for each. > Well a language
2018 Mar 19
2
Suggestions for how coroutines and UBSan codegen can play nice with one another?
Hello all! (+cc Vedant Kumar, who I've been told knows a lot about UBSan!) I am trying to fix an assert that occurs when the transforms in llvm/lib/Transforms/Coroutines are applied to LLVM IR that has been generated with UBSan enabled -- specifically, '-fsanitize=null'. You can see an example of the assert in this 26-line C++ file here: https://godbolt.org/g/Gw9UZq Note that
2016 Jun 13
3
[RFC] LLVM Coroutines
Hi Sanjoy: >> Now in the above CFG %val can be folded to 10, but in reality you need >> a PHI of 10 and 20 Quick answer: folding %val to 10 is OK, but, I would prefer it to be 'undef' or even catch it in the verifier as it is a programmer/frontend error. Details are in the second half of my reply. I would like to start with the thought experiment you suggested, as it might
2016 Jun 15
2
[RFC] LLVM Coroutines
Hi Sanjoy, >> I'm not familiar with fiber-type APIs, but I assume fiber_fork is like >> setjmp, in that it can "return twice"? Yes, user-mode stack switching API are somewhat similar to setjmp. Here are links to a doc page and implementation, just in case you are curious: http://www.boost.org/doc/libs/1_59_0/libs/context/doc/html/context/context.html
2016 Jun 09
6
Fwd: [RFC] LLVM Coroutines
Hi all: Below is a proposal to add experimental coroutine support to LLVM. Though this proposal is motivated primarily by the desire to support C++ Coroutines [1], the llvm representation is language neutral and can be used to support coroutines in other languages as well. Clang + llvm coroutines allows you to take this code: generator<int> range(int from, int to) { for(int i =
2018 Mar 19
0
Suggestions for how coroutines and UBSan codegen can play nice with one another?
> On Mar 19, 2018, at 3:44 PM, Brian Gesiak <modocache at gmail.com> wrote: > > Hello all! > (+cc Vedant Kumar, who I've been told knows a lot about UBSan!) > > I am trying to fix an assert that occurs when the transforms in llvm/lib/Transforms/Coroutines are applied to LLVM IR that has been generated with UBSan enabled -- specifically, '-fsanitize=null'. >
2019 Dec 26
2
[RFC] Coroutines passes in the new pass manager
Hello all, It's been a month since my previous email on the topic, and since then I've done some initial work on porting the coroutines passes to the new pass manager. In total there are 6 patches -- that's a lot to review, so allow me to introduce the changes being made in each of them. # What's finished In these first 6 patches, I focused on lowering coroutine intrinsics
2008 Jul 24
2
[LLVMdev] Erlang
Hello, How would you implement an Erlang feature such as the ultra-light processes? Is llvm prepared for similar situations? I would appreciate some insight on this. Thank you very much, .alvaro.castro.castilla.
2008 Jul 24
0
[LLVMdev] Erlang
Hi Álvaro, Your question is too vague to answer with any accuracy. Could you be more specific? -bw On Jul 24, 2008, at 1:08 PM, "Álvaro Castro Castilla" <alvaro.castro.castilla at gmail.co m> wrote: > Hello, > > > How would you implement an Erlang feature such as the ultra-light > processes? > Is llvm prepared for similar situations? > > I would
2016 Jun 10
2
[RFC] LLVM Coroutines
On Fri, Jun 10, 2016 at 6:36 AM, Gor Nishanov <gornishanov at gmail.com> wrote: > >> If you're going down that route, that still leaves the question of the > >> semantics of the fork intrinsic... thinking about it a bit more, I think > >> you're going to run into problems with trying to keep around a return > block > >> through optimizations:
2016 Jul 15
4
RFC: Coroutine Optimization Passes
Hi David: >> How do you deal with basic blocks which appear to be used by multiple parts >> of the coroutine? We handled this in WinEHPrepare by cloning any BBs which >> were shared. I experimented with several approaches, but, cloning ended up being the simplest and most reliable. Suspend points express three different control flows that can happen at the suspend point: a