GithubHelp home page GithubHelp logo

cheetah's People

Contributors

kyle-singer avatar neboat avatar voxsciurorum avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cheetah's Issues

Build fail on cmake

I am trying to build the cheetah runtime and on the cmake --build . step I get the following log:

CMakeFiles/cheetah_shared.dir/closure.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.h:8: multiple definition of `cilkrts_zero'
CMakeFiles/cheetah_shared.dir/cilk2c.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.h:8: first defined here
CMakeFiles/cheetah_shared.dir/fiber.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/init.h:12: multiple definition of `cilkg_nproc'
CMakeFiles/cheetah_shared.dir/cilk2c.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.c:17: first defined here
CMakeFiles/cheetah_shared.dir/global.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/init.h:12: multiple definition of `cilkg_nproc'
CMakeFiles/cheetah_shared.dir/cilk2c.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.c:17: first defined here
CMakeFiles/cheetah_shared.dir/init.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/init.h:12: multiple definition of `cilkg_nproc'
CMakeFiles/cheetah_shared.dir/cilk2c.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.c:17: first defined here
CMakeFiles/cheetah_shared.dir/invoke-main.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/init.h:12: multiple definition of `cilkg_nproc'
CMakeFiles/cheetah_shared.dir/cilk2c.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.c:17: first defined here
CMakeFiles/cheetah_shared.dir/invoke-main.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.h:8: multiple definition of `cilkrts_zero'
CMakeFiles/cheetah_shared.dir/cilk2c.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.h:8: first defined here
CMakeFiles/cheetah_shared.dir/personality.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.h:8: multiple definition of `cilkrts_zero'
CMakeFiles/cheetah_shared.dir/cilk2c.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.h:8: first defined here
CMakeFiles/cheetah_shared.dir/reducer_impl.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/init.h:12: multiple definition of `cilkg_nproc'
CMakeFiles/cheetah_shared.dir/cilk2c.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.c:17: first defined here
CMakeFiles/cheetah_shared.dir/ZERO.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.h:8: multiple definition of `cilkrts_zero'
CMakeFiles/cheetah_shared.dir/cilk2c.c.o:/home/giannis/cilk/opencilk-project/cheetah/runtime/cilk2c.h:8: first defined here
collect2: error: ld returned 1 exit status
gmake[2]: *** [runtime/CMakeFiles/cheetah_shared.dir/build.make:354: lib64/libopencilk.so.1.0] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:323: runtime/CMakeFiles/cheetah_shared.dir/all] Error 2
gmake[1]: *** Waiting for unfinished jobs....

Any ideas on how to fix this?

`dummy(alloca(ZERO))` in hand-compiled tests

Something I've noticed happens in all hand-compiled tests is the following line, right before the definition of a __cilkrts_stack_frame:

dummy(alloca(ZERO));

Why is this required? I'm guessing it's maintaining some invariant of the stack pointer, but I'm not sure why exactly. I'm trying to understand it as I work on my own hand-compiled code for the loop frame code.

Race condition in parallel build

Using make, the first parallel build of OpenCilk often fails because of a missing dependency:

ld: error: cannot open /usr/obj/Cilk/17/lib/clang/17/lib/freebsd/libclang_rt.asan_static-x86_64.a: No such file or directory
*** [/usr/obj/Cilk/17/lib/clang/17/lib/x86_64-unknown-freebsd13.2/libopencilk-asan-personality-c.so.1.0] Error code 1

This might happen more than once if all builds are parallel. Running make -k builds libclang_rt.asan_static and the next build will succeed. A serial build, make -j1, will also succeed.

My CmakeCache.txt says the runtime components appear in the order compiler-rt;cheetah;cilktools.

Cilk: stack mmap fails on WSL Linux (due to unsupported mmap operation using MAP_GROWSDOWN flag)

Minor issue, but just wanted to report this in case anyone else runs into similar problems.
I am unable to initialize the runtime when building/running using WSL (WIndows Subsystem for Linux).
Functional workaround seems to be to remove MAP_GROWSDOWN from the flags to mmap. I did not attempt to do any performance testing or any significant correctness tests however.

Details:

Basic programs (fib) fail with errno code 95, which is an unsupported operation, at the following line that calls mmap.

MAP_PRIVATE | MAP_ANONYMOUS | MAP_STACK | MAP_GROWSDOWN, -1, 0);

The MAP_GROWSDOWN flag seems to be unsupported on my test machine.
Building OpenCilk using WSL2 with Linux version Ubuntu 20.04.3 LTS. (Windows 10 build, 19043.1466)

I couldn't find any obvious documentation to indicate whether this is expected behavior for WSL Linux or not, so it might be a gap in the WSL implementation? TBD.

Worker local storage

We have a user request for a function to get the worker number, usable as an array index, but it's really a request for worker local storage.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.