Landing: 56e8379dd25e

Project / Subsystem

gcc / cobol

Date

2026-08-01

Author

Robert Dubner

Commit

56e8379dd25e53e9d716d3b5a45ad7de4da06809

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
cobol
patch_id
—
commit_hash
56e8379dd25e53e9d716d3b5a45ad7de4da06809
source_type
github
headline
Cobol: Use struct int128 for fixed-point arithmetic.
tldr
Refactors Cobol's fixed-point arithmetic to use a more convenient `struct int128` with `rdigits` member.
author
Robert Dubner
outcome
committed
performance_win
false
breaking_change
false
series_id
—
series_parts
[]
tags
  • • cobol
  • • fixed-point
  • • refactoring
  • • arithmetic
discussion_id_link
—
bugzilla_pr
—
date
2026-08-01T00:00:00.000Z

This commit enhances the Cobol compiler’s handling of fixed-point arithmetic by utilizing a struct int128 that includes an rdigits member. This structure simplifies the implementation by embedding the number of digits to the right of the decimal point directly within the data type, rather than managing it through external logic. The change impacts various functions across gcc/cobol and libgcobol that deal with numeric comparisons, multiplications, divisions, and formatting.