Skip to content

sigsegv with pure v program #22690

Description

@markfirmware

V doctor:

V full version: V 0.4.8 df4c6ac.5d76ee4
OS: linux, Debian GNU/Linux 12 (bookworm) (VM)
Processor: 1 cpus, 64bit, little endian, DO-Premium-AMD

getwd: /home/user/github.com/markfirmware/vlister
vexe: /home/user/github.com/vlang/v/v
vexe mtime: 2024-10-28 20:57:38

vroot: OK, value: /home/user/github.com/vlang/v
VMODULES: OK, value: /home/user/.vmodules
VTMP: OK, value: /tmp/v_1000

Git version: git version 2.39.5
Git vroot status: weekly.2024.43-58-g5d76ee46
.git/config present: true

CC version: cc (Debian 12.2.0-14) 12.2.0
thirdparty/tcc status: thirdparty-linux-amd64 0134e9b9

What did you do?
./v -g -o vdbg cmd/v && ./vdbg heap_sigsegv.v

@[heap]
struct Data {
  array [1024 * 1024]int
}

fn main() {
  d := Data{}
}

What did you expect to see?

no error

What did you see instead?

heap_sigsegv.v:7:3: warning: unused variable: `d`
    5 | 
    6 | fn main() {
    7 |   d := Data{}
      |   ^
    8 | }
Terminated by signal 11 (SIGSEGV)

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.

Huly®: V_0.6-21139

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: ConfirmedThis bug has been confirmed to be valid by a contributor.Unit: CompilerBugs/feature requests, that are related to the V compiler in general.Unit: cgenBugs/feature requests, that are related to the default C generating backend.

    Type

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions