You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@beam.apache.org by "Maksim Gaiduk (Jira)" <ji...@apache.org> on 2022/04/25 14:18:00 UTC

[jira] [Comment Edited] (BEAM-14237) Golang Beam ParDo job not working as expected on Apple M1 chip

    [ https://issues.apache.org/jira/browse/BEAM-14237?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17527517#comment-17527517 ] 

Maksim Gaiduk edited comment on BEAM-14237 at 4/25/22 2:17 PM:
---------------------------------------------------------------

Do you use arm64 GO binary?

I've noticed that default GO installation is amd64, which will cause M1 macs to launch go executables through Rosetta compatibility layer. I've tried this on my M1 and UB was gone when compiling for amd64 and running through Rosetta

UPD: Asked a colleague with M1 pro 14" 2021 - he sees the same sigsegv

My mac is M1 pro 16'' 2021


was (Author: JIRAUSER287522):
Do you use arm64 GO binary?

I've noticed that default GO installation is amd64, which will cause M1 macs to launch go executables through Rosetta compatibility layer. I've tried this on my M1 and UB was gone when compiling for amd64 and running through Rosetta

> Golang Beam ParDo job not working as expected on Apple M1 chip
> --------------------------------------------------------------
>
>                 Key: BEAM-14237
>                 URL: https://issues.apache.org/jira/browse/BEAM-14237
>             Project: Beam
>          Issue Type: Bug
>          Components: sdk-go
>    Affects Versions: 2.37.0
>            Reporter: Maksim Gaiduk
>            Assignee: Jack McCluskey
>            Priority: P2
>
> Reproducible example:
> reproducible.go: [https://pastebin.com/raw/LqADath4]
> go.mod: [https://pastebin.com/raw/qXmyh62N]
> run cmd: go run reproducible.go --output output.tsv
> On lines 29-31, the program is supposed to read from rowIter function only while new data is available (this is standard interface to read input after GroupBy operation).
> Instead, the cycle runs indefinitely. In gdb/debug prints it can be clearly seen that program just steps through the "if !b" block when "b" is false.
> Supposedly this is the cause of UB from ABI function call inside beam.
>  
> Go version: go1.18 darwin/arm64



--
This message was sent by Atlassian Jira
(v8.20.7#820007)