Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor cmm functions to be more generic over operand width #3404

Draft
wants to merge 3 commits into
base: cmm-refactor-unboxed-fields
Choose a base branch
from

Conversation

jvanburen
Copy link
Contributor

No description provided.

Copy link

Selection Change Check

This PR modifies the original selection pass (targeting Mach).
Please check whether the changes should also be applied to the
CFG variant of the pass.

@jvanburen
Copy link
Contributor Author

This PR refactors cmm_helpers in preparation for unboxed 8 and 16-bit integers to be added to the compiler.
It replaces many functions that were copied for each width with a single more generic version, and then updates to_cmm to use it.

@jvanburen jvanburen marked this pull request as ready for review December 23, 2024 21:36
@jvanburen jvanburen requested a review from mshinwell December 23, 2024 21:36
@jvanburen jvanburen marked this pull request as draft December 27, 2024 21:06
@jvanburen jvanburen changed the base branch from main to cmm-refactor-unboxed-fields January 2, 2025 19:55
commit d1acc48
Author: Jacob Van Buren <[email protected]>
Date:   Thu Jan 2 14:53:51 2025 -0500

    Squashed commit of the following:

    commit c9d7aa6
    Author: Jacob Van Buren <[email protected]>
    Date:   Thu Jan 2 14:49:45 2025 -0500

        cleaned up div/mod

    commit 4d9f427
    Author: Jacob Van Buren <[email protected]>
    Date:   Thu Jan 2 14:45:42 2025 -0500

        address feedback and simplify division interface

commit 625a416
Author: Jacob Van Buren <[email protected]>
Date:   Tue Dec 31 11:00:07 2024 -0500

    unified unboxed field getters/setters. This will be useful once we have unboxed integers of different sizes

commit 37b4e82
Author: Jacob Van Buren <[email protected]>
Date:   Tue Dec 31 09:40:53 2024 -0500

    formatted

commit 1746aa8
Author: Jacob Van Buren <[email protected]>
Date:   Mon Dec 30 11:37:33 2024 -0500

    updated cmm_helpers interface to be more amenable to adding other integer sizes

commit 9e7c322
Author: Greta Yorsh <[email protected]>
Date:   Tue Dec 31 12:01:21 2024 +0000

    Separate test for vectorizer in the CI (#3414)

    * Separate test for vectorizer in the CI

    * Remove vectorizer from "gi" CI job

commit e1a5fe4
Author: Xavier Clerc <[email protected]>
Date:   Tue Dec 31 10:54:43 2024 +0000

    CI: simplify the regalloc jobs (#3389)

commit ab229fc
Author: Greta Yorsh <[email protected]>
Date:   Tue Dec 31 10:42:37 2024 +0000

    ASR 64-bit lane not available in sse instruction (#3413)

commit 8b99545
Author: Thomas Del Vecchio <[email protected]>
Date:   Mon Dec 30 14:26:48 2024 -0500

    Fix case where parser drops attributes in packed module types. (#3262)

    * Demonstrate dropped attributes in test.

    Signed-off-by: Thomas Del Vecchio <[email protected]>

    * Syntax error on misplaced attribute in packed module types.

    Signed-off-by: Thomas Del Vecchio <[email protected]>

    ---------

    Signed-off-by: Thomas Del Vecchio <[email protected]>

commit fe97beb
Author: Aspen Smith <[email protected]>
Date:   Sat Dec 28 11:47:55 2024 -0500

    Add attributes to (unsafely) skip jkind check  (#3385)

    * Add attributes to (unsafely) skip jkind check

    Add a pair of attributes, [@@unsafe_allow_any_kind_in_intf] and
    [@@unsafe_allow_any_kind_in_impl], which if set on both the impl and the intf
    respectively, skip checking the jkind of the type in a signature against the
    jkind of the type in a struct entirely. This is a more-selective version of the
    `--allow-illegal-crossing` flag, and likely eventually subsumes it.

    Signed-off-by: Aspen Smith <[email protected]>

    * Emit a warning when unsafe_allow_any_kind is added unnecessarily

    Note that this is /only/ done if the attribute is set in both signatures but not
    used - also this is a little over-sensitive (sadly) since this is done during
    sigature inclusion too. A new test covers the over-sensitivity.

    Signed-off-by: Aspen Smith <[email protected]>

    ---------

    Signed-off-by: Aspen Smith <[email protected]>

commit 862ced2
Author: dkalinichenko-js <[email protected]>
Date:   Thu Dec 26 15:20:06 2024 -0500

    Add `Variant_with_null` and `Null` variant constructors (#2870)

    * `Variant_with_null`

    * `Null` tagged constructors

    * precise value kind

    * No private re-export

    ---------

    Co-authored-by: Diana Kalinichenko <[email protected]>

commit 1eeed87
Author: Mark Shinwell <[email protected]>
Date:   Thu Dec 26 15:00:49 2024 +0000

    Revert "Implement %makearray_dynamic{,_uninit}" (#3408)

    Revert "Implement %makearray_dynamic{,_uninit} (#3317)"

    This reverts commit 6da1dde.

commit 2358e09
Author: Mark Shinwell <[email protected]>
Date:   Tue Dec 24 15:54:06 2024 +0000

    Upload core files etc upon CI failure (#3405)

commit dc6e300
Author: Xavier Clerc <[email protected]>
Date:   Tue Dec 24 10:06:20 2024 +0100

    Fix IRC and Greedy allocators (arm64) (#3388)

commit 65c0596
Author: Max Slater <[email protected]>
Date:   Mon Dec 23 16:49:37 2024 -0500

    Convert float32 constants to int32 in first stage compiler (#3371)

    * convert float32 constants in bytecode output

    * edit

    * edit

    * blocks + test

    * compare against float64 constants

    * tests check proper custom ops

    ---------

    Co-authored-by: Diana Kalinichenko <[email protected]>
Copy link

github-actions bot commented Jan 2, 2025

Parser Change Checklist

This PR modifies the parser. Please check that the following tests are updated:

  • parsetree/source_jane_street.ml

This test should have examples of every new bit of syntax you are adding. Feel free to just check the box if your PR does not actually change the syntax (because it is refactoring the parser, say).

@jvanburen jvanburen force-pushed the cmm-refactor-unboxed-fields branch from d1acc48 to abcd725 Compare January 3, 2025 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant