diff --git a/.github/workflows/bootstrapping_ci.yml b/.github/workflows/bootstrapping_ci.yml index e618c09710..e5807812cd 100644 --- a/.github/workflows/bootstrapping_ci.yml +++ b/.github/workflows/bootstrapping_ci.yml @@ -34,7 +34,7 @@ jobs: os: [ubuntu-latest, macos-14] fail-fast: false runs-on: ${{ matrix.os }} - timeout-minutes: 10 + timeout-minutes: 15 env: VFLAGS: -no-parallel B_LFLAGS: -lm -lpthread diff --git a/.github/workflows/c2v_ci.yml b/.github/workflows/c2v_ci.yml index 8b655030d3..48f2279031 100644 --- a/.github/workflows/c2v_ci.yml +++ b/.github/workflows/c2v_ci.yml @@ -29,7 +29,7 @@ concurrency: jobs: build-doom: runs-on: ubuntu-24.04 - timeout-minutes: 20 + timeout-minutes: 30 steps: - uses: actions/checkout@v5 - name: Build V diff --git a/.github/workflows/cross_ci.yml b/.github/workflows/cross_ci.yml index 078640e31f..d2c402d344 100644 --- a/.github/workflows/cross_ci.yml +++ b/.github/workflows/cross_ci.yml @@ -23,7 +23,7 @@ concurrency: jobs: cross-macos: runs-on: macos-13 - timeout-minutes: 10 + timeout-minutes: 15 env: VFLAGS: -cc clang steps: @@ -53,7 +53,7 @@ jobs: cross-linux: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 env: VFLAGS: -cc tcc -no-retry-compilation steps: @@ -102,7 +102,7 @@ jobs: cross-windows: runs-on: windows-2025 - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 - name: Build diff --git a/.github/workflows/docs_ci.yml b/.github/workflows/docs_ci.yml index 4a5d5daddc..14202ef336 100644 --- a/.github/workflows/docs_ci.yml +++ b/.github/workflows/docs_ci.yml @@ -23,7 +23,7 @@ concurrency: jobs: check-markdown: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 - name: Build V @@ -59,7 +59,7 @@ jobs: report-missing-dots-in-doc-comments: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 - name: Build V diff --git a/.github/workflows/gen_vc_ci.yml b/.github/workflows/gen_vc_ci.yml index 4c3131a10e..5adaf8a2e8 100644 --- a/.github/workflows/gen_vc_ci.yml +++ b/.github/workflows/gen_vc_ci.yml @@ -30,7 +30,7 @@ concurrency: jobs: build-vc: runs-on: ubuntu-latest - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 - name: Build V diff --git a/.github/workflows/gg_regressions_ci.yml b/.github/workflows/gg_regressions_ci.yml index f554ceb760..36690cd31a 100644 --- a/.github/workflows/gg_regressions_ci.yml +++ b/.github/workflows/gg_regressions_ci.yml @@ -23,7 +23,7 @@ concurrency: jobs: gg-regressions: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 env: VFLAGS: -cc tcc DISPLAY: :99 diff --git a/.github/workflows/module_docs_ci.yml b/.github/workflows/module_docs_ci.yml index 26280518a7..062d4abe7a 100644 --- a/.github/workflows/module_docs_ci.yml +++ b/.github/workflows/module_docs_ci.yml @@ -31,7 +31,7 @@ concurrency: jobs: build-module-docs: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 - name: Build V diff --git a/.github/workflows/more_extensive_but_slower_tests_ci.yml b/.github/workflows/more_extensive_but_slower_tests_ci.yml index 90eb1a6328..3884fe5172 100644 --- a/.github/workflows/more_extensive_but_slower_tests_ci.yml +++ b/.github/workflows/more_extensive_but_slower_tests_ci.yml @@ -26,7 +26,7 @@ jobs: matrix: os: [ubuntu-latest, macos-14, windows-latest] runs-on: ${{ matrix.os }} - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 diff --git a/.github/workflows/other_ci.yml b/.github/workflows/other_ci.yml index f6b6a16850..481565e8f9 100644 --- a/.github/workflows/other_ci.yml +++ b/.github/workflows/other_ci.yml @@ -67,7 +67,7 @@ jobs: code-formatting: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 env: VFLAGS: -cc gcc steps: @@ -107,7 +107,7 @@ jobs: misc-tooling: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 env: VFLAGS: -cc tcc -no-retry-compilation steps: diff --git a/.github/workflows/paths_ci.yml b/.github/workflows/paths_ci.yml index 7f60a704f9..7cefd1f93d 100644 --- a/.github/workflows/paths_ci.yml +++ b/.github/workflows/paths_ci.yml @@ -24,7 +24,7 @@ concurrency: jobs: space-paths-linux: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 with: diff --git a/.github/workflows/sdl_ci.yml b/.github/workflows/sdl_ci.yml index ef46d07001..c8744617a9 100644 --- a/.github/workflows/sdl_ci.yml +++ b/.github/workflows/sdl_ci.yml @@ -26,7 +26,7 @@ concurrency: jobs: v-compiles-sdl-examples: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 env: VFLAGS: -cc tcc steps: diff --git a/.github/workflows/toml_ci.yml b/.github/workflows/toml_ci.yml index 17258ee3fa..4d8d44e5cd 100644 --- a/.github/workflows/toml_ci.yml +++ b/.github/workflows/toml_ci.yml @@ -19,7 +19,7 @@ concurrency: jobs: toml-module-pass-external-test-suites: runs-on: ubuntu-latest - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 - name: Build V diff --git a/.github/workflows/tools_ci.yml b/.github/workflows/tools_ci.yml index 95f1261573..0b63c57ed8 100644 --- a/.github/workflows/tools_ci.yml +++ b/.github/workflows/tools_ci.yml @@ -65,7 +65,7 @@ jobs: tools-macos: runs-on: macos-14 - timeout-minutes: 10 + timeout-minutes: 15 strategy: matrix: cc: [clang] diff --git a/.github/workflows/v_apps_and_modules_compile_ci.yml b/.github/workflows/v_apps_and_modules_compile_ci.yml index 9e4f333014..618bda6f25 100644 --- a/.github/workflows/v_apps_and_modules_compile_ci.yml +++ b/.github/workflows/v_apps_and_modules_compile_ci.yml @@ -237,7 +237,7 @@ jobs: os: [ubuntu-24.04, macos-14] fail-fast: false runs-on: ${{ matrix.os }} - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 - name: Build V diff --git a/.github/workflows/vab_ci.yml b/.github/workflows/vab_ci.yml index c107570bf4..e47645e77c 100644 --- a/.github/workflows/vab_ci.yml +++ b/.github/workflows/vab_ci.yml @@ -24,7 +24,7 @@ concurrency: jobs: vab-compiles-v-examples: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 env: VAB_FLAGS: --api 30 --build-tools 29.0.0 -v 3 steps: diff --git a/.github/workflows/vinix_ci.yml b/.github/workflows/vinix_ci.yml index 486d801ee7..bc91e0b805 100644 --- a/.github/workflows/vinix_ci.yml +++ b/.github/workflows/vinix_ci.yml @@ -24,7 +24,7 @@ concurrency: jobs: vinix-build: runs-on: ubuntu-24.04 - timeout-minutes: 10 + timeout-minutes: 15 steps: - uses: actions/checkout@v5 - name: Build V diff --git a/.github/workflows/vup_works.yml b/.github/workflows/vup_works.yml index 95562025a0..5c143f0413 100644 --- a/.github/workflows/vup_works.yml +++ b/.github/workflows/vup_works.yml @@ -37,7 +37,7 @@ jobs: - os: macos-14 zip: v_macos_arm64.zip runs-on: ${{ matrix.os }} - timeout-minutes: 10 + timeout-minutes: 15 env: VDIR: /tmp/v_from_release_zip steps: diff --git a/.github/workflows/wasm_backend_ci.yml b/.github/workflows/wasm_backend_ci.yml index c07c4ea955..64bcd824e1 100644 --- a/.github/workflows/wasm_backend_ci.yml +++ b/.github/workflows/wasm_backend_ci.yml @@ -49,7 +49,7 @@ jobs: matrix: os: [ubuntu-22.04, windows-2022] fail-fast: false - timeout-minutes: 10 + timeout-minutes: 15 env: VTEST_ONLY: wasm steps: diff --git a/cmd/tools/vretry.v b/cmd/tools/vretry.v index e3af7c8f22..f62262c1d1 100644 --- a/cmd/tools/vretry.v +++ b/cmd/tools/vretry.v @@ -22,7 +22,7 @@ fn main() { fp.skip_executable() fp.limit_free_args_to_at_least(1)! context.show_help = fp.bool('help', `h`, false, 'Show this help screen.') - context.timeout = fp.float('timeout', `t`, 600.0, 'Timeout in seconds (for all retries). Default: 600.0 seconds (10 minutes).') * time.second + context.timeout = fp.float('timeout', `t`, 900.0, 'Timeout in seconds (for all retries). Default: 900.0 seconds (15 minutes).') * time.second context.delay = fp.float('delay', `d`, 1.0, 'Delay between each retry in seconds. Default: 1.0 second.') * time.second context.retries = fp.int('retries', `r`, 10, 'Maximum number of retries. Default: 10.') if context.show_help { diff --git a/thirdparty/fontstash/fontstash.h b/thirdparty/fontstash/fontstash.h index bd42a0002e..cb00bd63fe 100644 --- a/thirdparty/fontstash/fontstash.h +++ b/thirdparty/fontstash/fontstash.h @@ -38,6 +38,9 @@ extern "C" { #define FONTSTASH_MALLOC malloc #define FONTSTASH_REALLOC realloc #define FONTSTASH_FREE free +// __v_ start +#define FONTSTASH_MALLOC_ATOMIC malloc +// __v_ end #endif enum FONSflags { @@ -563,7 +566,7 @@ static FONSatlas* fons__allocAtlas(int w, int h, int nnodes) atlas->height = h; // Allocate space for skyline nodes - atlas->nodes = (FONSatlasNode*)FONTSTASH_MALLOC(sizeof(FONSatlasNode) * nnodes); + atlas->nodes = (FONSatlasNode*)FONTSTASH_MALLOC_ATOMIC(sizeof(FONSatlasNode) * nnodes); if (atlas->nodes == NULL) goto error; memset(atlas->nodes, 0, sizeof(FONSatlasNode) * nnodes); atlas->nnodes = 0; @@ -780,7 +783,7 @@ FONScontext* fonsCreateInternal(FONSparams* params) // Create texture for the cache. stash->itw = 1.0f/stash->params.width; stash->ith = 1.0f/stash->params.height; - stash->texData = (unsigned char*)FONTSTASH_MALLOC(stash->params.width * stash->params.height); + stash->texData = (unsigned char*)FONTSTASH_MALLOC_ATOMIC(stash->params.width * stash->params.height); if (stash->texData == NULL) goto error; memset(stash->texData, 0, stash->params.width * stash->params.height); @@ -901,7 +904,7 @@ static int fons__allocFont(FONScontext* stash) if (font == NULL) goto error; memset(font, 0, sizeof(FONSfont)); - font->glyphs = (FONSglyph*)FONTSTASH_MALLOC(sizeof(FONSglyph) * FONS_INIT_GLYPHS); + font->glyphs = (FONSglyph*)FONTSTASH_MALLOC_ATOMIC(sizeof(FONSglyph) * FONS_INIT_GLYPHS); if (font->glyphs == NULL) goto error; font->cglyphs = FONS_INIT_GLYPHS; font->nglyphs = 0; @@ -1657,7 +1660,7 @@ FONS_DEF int fonsExpandAtlas(FONScontext* stash, int width, int height) return 0; } // Copy old texture data over. - data = (unsigned char*)FONTSTASH_MALLOC(width * height); + data = (unsigned char*)FONTSTASH_MALLOC_ATOMIC(width * height); if (data == NULL) return 0; for (i = 0; i < stash->params.height; i++) { diff --git a/vlib/fontstash/fontstash.c.v b/vlib/fontstash/fontstash.c.v index 9a67f57838..72f0a7c663 100644 --- a/vlib/fontstash/fontstash.c.v +++ b/vlib/fontstash/fontstash.c.v @@ -8,6 +8,7 @@ $if gcboehm ? { #define FONTSTASH_MALLOC GC_MALLOC #define FONTSTASH_REALLOC GC_REALLOC #define FONTSTASH_FREE GC_FREE + #define FONTSTASH_MALLOC_ATOMIC GC_MALLOC_ATOMIC } #include "fontstash.h" #flag darwin -I/usr/local/Cellar/freetype/2.10.2/include/freetype2 diff --git a/vlib/v/builder/cc.v b/vlib/v/builder/cc.v index d3f6e54642..fae4c06173 100644 --- a/vlib/v/builder/cc.v +++ b/vlib/v/builder/cc.v @@ -302,6 +302,7 @@ fn (mut v Builder) setup_ccompiler_options(ccompiler string) { // have much better performance when NDEBUG is defined // See also http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1256.pdf ccoptions.args << '-DNDEBUG' + ccoptions.args << '-DNO_DEBUGGING' // for BDWGC } if v.pref.sanitize { ccoptions.args << '-fsanitize=leak' diff --git a/vlib/v/builder/msvc_windows.v b/vlib/v/builder/msvc_windows.v index efabe1048f..1685613ade 100644 --- a/vlib/v/builder/msvc_windows.v +++ b/vlib/v/builder/msvc_windows.v @@ -291,6 +291,7 @@ pub fn (mut v Builder) cc_msvc() { } else { a << '/MD' a << '/DNDEBUG' + a << '/DNO_DEBUGGING' if !v.ccoptions.debug_mode { v.pref.cleanup_files << out_name_pdb v.pref.cleanup_files << app_dir_out_name + '.pdb' @@ -458,6 +459,7 @@ fn (mut v Builder) build_thirdparty_obj_file_with_msvc(_mod string, path string, oargs << '/O2' oargs << '/MD' oargs << '/DNDEBUG' + oargs << '/DNO_DEBUGGING' } } else { oargs << '/MDd'