GithubHelp home page GithubHelp logo

blu / constexpr_raycaster Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 18 KB

A constexpr raycaster: burn obscene amounts of RAM and CPU cycles for science!

License: MIT License

C++ 99.57% Shell 0.43%

constexpr_raycaster's Introduction

Description

This is an experiment in compile-time eval on c++-14 and above. Test constitutes the computation of an image via raycasting over a minimalistic scene of voxels. The practical value of this project is nil, aside for torturing the compiler.

Test passes successfully on:

compiler, RAM amount
g++-6.3.0, 8GB RAM
g++-7.4.0, 6GB RAM, 14GB swap
g++-8.1.0, 16GB RAM
g++-8.2.0, 4GB ZRAM
g++-8.3.0, 4GB ZRAM
g++-9.1.0, unknown (godbolt.org); output reduced to 128x128
g++-9.2.0, unknown (godbolt.org); output reduced to 128x128

Test fails for various reasons on other compilers. Such as:

  • not-constexpr pure functions in cmath
  • not-fully-c++14-compliant constexpr support
  • compiler runs out of (virtual) memory

constexpr_raycaster's People

Contributors

blu avatar

Watchers

 avatar  avatar

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.