Skip to content

Simple example with segmentaion fault #8761

@maranGit

Description

@maranGit

Describe the bug

This simple example produces Received signal 11 (Segmentation fault)

To Reproduce

import taichi as ti ti.init(arch=ti.cpu, debug=True)
w = ti.Vector.field(3, dtype=float, shape = 20)

@ti.kernel
def test():
reset()
get_weight(1)

@ti.func
def get_weight(i):
print(w[0][i])

@ti.func
def reset():
w[0] = ti.Vector([1., 2., 3.])

test()

Log/Screenshots

Image

Additional comments

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Untriaged

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions