Giter Site home page Giter Site logo

mhonert / velvet-chess Goto Github PK

View Code? Open in Web Editor NEW
33.0 6.0 2.0 166.09 MB

:chess_pawn: Velvet Chess Engine - written in Rust

License: GNU General Public License v3.0

Rust 76.80% Python 3.02% Shell 0.01% C++ 1.38% C 18.80%
chess chess-engine rust uci machine-learning neural-network

velvet-chess's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  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

Forkers

yibit shintakezou

velvet-chess's Issues

Build Issue: thread '<unknown>' has overflowed its stack

This happens on my Ubuntu box, and on a WSL Ubuntu image. I have attempted to increase the stack size, by cd'ing into the engine dir and building via cargo rustc --release --bin velvet -- -C link-args=-Wl,-zstack-size=16777216. This did not work.

Analog Hors suggested the following code change to spawn_engine_thread(), which worked for him.

    std::thread::Builder::new().stack_size(20_000_000).spawn(move || {
        let mut engine = Engine::new(rx);
        engine.start_loop();
    }).unwrap();

A portion of the conversation that was had:

image

Ponder and/or FRC?

Hi, great to see progress on the engine! It's almost "TCEC Ready" with the NNUE strength. Do you have plans to implement ponder and/or FRC support?

Android compatibility

When cross compiling to Android with the following command
cargo build --release --bin velvet --target=aarch64-linux-android
I get the following error messages (version 5.0.0 still worked):

warning: In file included from fathom/src/tbprobe.c:50:
warning: /usr/include/pthread.h:681:6: error: 'regparm' is not valid on this platform
warning: __cleanup_fct_attribute;
warning: ^~~~~~~~~~~~~~~~~~~~~~~
warning: /usr/include/bits/pthreadtypes.h:255:50: note: expanded from macro '__cleanup_fct_attribute'
warning: # define __cleanup_fct_attribute attribute ((regparm (1)))
warning: ^ ~
warning: In file included from fathom/src/tbprobe.c:50:
warning: /usr/include/pthread.h:693:3: error: 'regparm' is not valid on this platform
warning: __cleanup_fct_attribute;
warning: ^~~~~~~~~~~~~~~~~~~~~~~
warning: /usr/include/bits/pthreadtypes.h:255:50: note: expanded from macro '__cleanup_fct_attribute'
warning: # define __cleanup_fct_attribute attribute ((regparm (1)))
warning: ^ ~
warning: In file included from fathom/src/tbprobe.c:50:
warning: /usr/include/pthread.h:734:6: error: 'regparm' is not valid on this platform
warning: __cleanup_fct_attribute attribute ((noreturn))
warning: ^~~~~~~~~~~~~~~~~~~~~~~
warning: /usr/include/bits/pthreadtypes.h:255:50: note: expanded from macro '__cleanup_fct_attribute'
warning: # define __cleanup_fct_attribute attribute ((regparm (1)))
warning: ^ ~
warning: fathom/src/tbprobe.c:247:10: warning: value size does not match register size specified by the constraint and modifier [-Wasm-operand-widths]
warning: return bswap64(input);
warning: ^
warning: fathom/src/stdendian.h:86:33: note: expanded from macro 'bswap64'
warning: #define bswap64(x) bswap_64(x)
warning: ^
warning: /usr/include/byteswap.h:37:21: note: expanded from macro 'bswap_64'
warning: #define bswap_64(x) __bswap_64 (x)
warning: ^
warning: /usr/include/bits/byteswap.h:132:20: note: expanded from macro '__bswap_64'
warning: __r.__l[0] = __bswap_32 (__w.__l[1]);
warning: ^
warning: /usr/include/bits/byteswap.h:76:16: note: expanded from macro '__bswap_32'
warning: : "=r" (__v)
warning: ^
warning: fathom/src/tbprobe.c:247:10: note: use constraint modifier "w"
warning: fathom/src/stdendian.h:86:33: note: expanded from macro 'bswap64'
warning: #define bswap64(x) bswap_64(x)
warning: ^
warning: /usr/include/byteswap.h:37:21: note: expanded from macro 'bswap_64'
warning: #define bswap_64(x) __bswap_64 (x)
warning: ^
warning: /usr/include/bits/byteswap.h:132:20: note: expanded from macro '__bswap_64'
warning: __r.__l[0] = __bswap_32 (__w.__l[1]);
warning: ^
warning: /usr/include/bits/byteswap.h:74:19: note: expanded from macro '__bswap_32'
warning: "rorl $16, %0;"
warning: ^
warning: fathom/src/tbprobe.c:247:10: warning: value size does not match register size specified by the constraint and modifier [-Wasm-operand-widths]
warning: return bswap64(input);
warning: ^
warning: fathom/src/stdendian.h:86:33: note: expanded from macro 'bswap64'
warning: #define bswap64(x) bswap_64(x)
warning: ^
warning: /usr/include/byteswap.h:37:21: note: expanded from macro 'bswap_64'
warning: #define bswap_64(x) __bswap_64 (x)
warning: ^
warning: /usr/include/bits/byteswap.h:133:20: note: expanded from macro '__bswap_64'
warning: __r.__l[1] = __bswap_32 (__w.__l[0]);
warning: ^
warning: /usr/include/bits/byteswap.h:76:16: note: expanded from macro '__bswap_32'
warning: : "=r" (__v)
warning: ^
warning: fathom/src/tbprobe.c:247:10: note: use constraint modifier "w"
warning: fathom/src/stdendian.h:86:33: note: expanded from macro 'bswap64'
warning: #define bswap64(x) bswap_64(x)
warning: ^
warning: /usr/include/byteswap.h:37:21: note: expanded from macro 'bswap_64'
warning: #define bswap_64(x) __bswap_64 (x)
warning: ^
warning: /usr/include/bits/byteswap.h:133:20: note: expanded from macro '__bswap_64'
warning: __r.__l[1] = __bswap_32 (__w.__l[0]);
warning: ^
warning: /usr/include/bits/byteswap.h:74:19: note: expanded from macro '__bswap_32'
warning: "rorl $16, %0;"
warning: ^
warning: fathom/src/tbprobe.c:251:10: warning: value size does not match register size specified by the constraint and modifier [-Wasm-operand-widths]
warning: return bswap32(input);
warning: ^
warning: fathom/src/stdendian.h:85:33: note: expanded from macro 'bswap32'
warning: #define bswap32(x) bswap_32(x)
warning: ^
warning: /usr/include/byteswap.h:34:21: note: expanded from macro 'bswap_32'
warning: #define bswap_32(x) __bswap_32 (x)
warning: ^
warning: /usr/include/bits/byteswap.h:76:16: note: expanded from macro '__bswap_32'
warning: : "=r" (__v)
warning: ^
warning: fathom/src/tbprobe.c:251:10: note: use constraint modifier "w"
warning: fathom/src/stdendian.h:85:33: note: expanded from macro 'bswap32'
warning: #define bswap32(x) bswap_32(x)
warning: ^
warning: /usr/include/byteswap.h:34:21: note: expanded from macro 'bswap_32'
warning: #define bswap_32(x) __bswap_32 (x)
warning: ^
warning: /usr/include/bits/byteswap.h:74:19: note: expanded from macro '__bswap_32'
warning: "rorl $16, %0;"
warning: ^
warning: fathom/src/tbprobe.c:1605:12: warning: cast to 'uint8_t *' (aka 'unsigned char *') from smaller integer type 'unsigned int' [-Wint-to-pointer-cast]
warning: data = (uint8_t *)(((uintptr_t)data + 0x3f) & ~0x3f);
warning: ^
warning: fathom/src/tbprobe.c:1609:14: warning: cast to 'uint8_t *' (aka 'unsigned char *') from smaller integer type 'unsigned int' [-Wint-to-pointer-cast]
warning: data = (uint8_t *)(((uintptr_t)data + 0x3f) & ~0x3f);
warning: ^
warning: fathom/src/tbprobe.c:2459:41: warning: comparison of integers of different signs: 'int' and 'unsigned int' [-Wsign-compare]
warning: if (popcount(pos->white | pos->black) <= cardinalityDTM) {
warning: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~
warning: 6 warnings and 3 errors generated.

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.