Skip to content

log: log.info breaks with -cc gcc, -prod and -cflags -fno-inline-small-functions at runtime #24874

@esquerbatua

Description

@esquerbatua

Describe the bug

Run build with flags, using log.info

Reproduction Steps

compile with: v -prod -cflags "-fno-inline-small-functions" .

module main

import log

fn main() {
	println('Hello, World!')
	log.info('test')
}

Expected Behavior

Hello, World!
<time> [INFO ] test

Current Behavior

V panic: invalid log_default_level: info
v hash: 499283e
addr2line: '[0x401b3c]': No such file
[0x401b3c]
addr2line: '[0x41db48]': No such file
[0x41db48]
addr2line: '[0x41fd10]': No such file
[0x41fd10]
addr2line: '[0x401b65]': No such file
[0x401b65]

Possible Solution

No response

Additional Information/Context

No response

V version

V 0.4.11 f822792.ee6eed3

Environment details (OS name and version, etc.)

V full version V 0.4.11 f822792.ee6eed3
OS linux, Ubuntu 24.04.2 LTS
Processor 16 cpus, 64bit, little endian, AMD Ryzen 7 7840HS w/ Radeon 780M Graphics
Memory 60.5GB/86.23GB
V executable /home/esquerbatua/git/v/v
V last modified time 2025-07-10 10:12:50
V home dir OK, value: /home/esquerbatua/git/v
VMODULES OK, value: /home/esquerbatua/.vmodules
VTMP OK, value: /tmp/v_1000
Git version git version 2.43.0
V git status 0.4.11-96-gee6eed3c
.git/config present true
cc version cc (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0
gcc version gcc (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0
clang version N/A
tcc version tcc version 0.9.28rc 2025-02-13 HEAD@f8bd136d (x86_64 Linux)
tcc git status thirdparty-linux-amd64 696c1d84
emcc version N/A
glibc version ldd (Ubuntu GLIBC 2.39-0ubuntu8.4) 2.39

Note

You can use the 👍 reaction to increase the issue's priority for developers.

Please note that only the 👍 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugThis tag is applied to issues which reports bugs.Compiler: GCCBugs/feature requests, that are related to compiler GCC.OS: LinuxBugs/feature requests, that are specific to Linux-based OS.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions