diff options
| author | eunhhu <[email protected]> | 2026-10-19 01:53:40 +0100 |
|---|---|---|
| committer | eunhhu <[email protected]> | 2026-10-19 01:53:40 +0100 |
| commit | defb2cf06a9b5db9429ca368d8c2af127a5c9c3d (patch) | |
| tree | b13c94eb334ce2a5055854791900f8702ba9fc3b /docs/design/027-computation-core.md | |
| parent | 809a83a5764ec0f0c84b96c43a20cfb906eee031 (diff) | |
| download | pure-defb2cf06a9b5db9429ca368d8c2af127a5c9c3d.tar.gz pure-defb2cf06a9b5db9429ca368d8c2af127a5c9c3d.zip | |
027's 5c: money as i64 minor units shown by .Nd: NUM_TEXT's decimal form takes digits (bits 20-24 as FIXED's), an integer's last N digits written after a point (1234 at two is 12.34, -5 -0.05, 0 0.00; width and zeros after the sign), verification allowing digits on FIXED and DECIMAL alone; unit test: ten rows of formats_and_held (-2^63 at two, 25 digits, a number's whole 1234, its 12.5 a limit); TPC-C's money i64 cents and its rates ten-thousandths (tables, messages, load, the transactions), SQLite's INTEGER columns and int64 bindings alike, the comparison now exact (no 1e-9 tolerance): after 20,000 transactions every row of every table the same (grouped SQLite too) and 3.3.2 holding on both; counts: b45 against b44 BFS without batches +0.09%, the rest within 0.001%; the bank's queries (s44 and s45 in turns, six each) in_credit -0.59%, per_branch -0.34%, ranks -0.20%, the rest within 0.01%, the seven answers the same bytes; 008 (NUM_TEXT's digits, a message row's i64 cells), 027 and 092
Diffstat (limited to 'docs/design/027-computation-core.md')
| -rw-r--r-- | docs/design/027-computation-core.md | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/docs/design/027-computation-core.md b/docs/design/027-computation-core.md index 0813958..6d24433 100644 --- a/docs/design/027-computation-core.md +++ b/docs/design/027-computation-core.md @@ -548,6 +548,18 @@ - 명령 수(b44 대 b43): ±0.04% 안이다(실행기만의 BFS −0.03%). 은행 질의(s43과 s44를 한 번에 번갈아 여섯 번의 중앙값)는 per_branch −1.32%(여섯 번 모두 s43의 가장 낮은 것 아래: Fold가 커져 number 합의 고리가 달리 놓였다), in_credit −0.72%, ranks −0.26%, 나머지 ±0.01% 안이다. 일곱 질의의 답은 두 빌드에서 바이트까지 같다. + - **5c 만듦(2026-10-19).** + - Pure: NUM_TEXT의 10진 꼴이 자릿수를 받는다. 정수를 최소 단위로 보고 끝의 그 자릿수를 소수점 뒤에 쓴다(2자리에서 1234는 + `12.34`, −5는 `-0.05`, 0은 `0.00`). 폭과 0 채우기는 다른 꼴처럼 부호 뒤다. 검증은 자릿수를 고정 소수와 10진에만 허락한다. + - aup: `{cents:.2d}`. 파이썬에 없는 꼴이라, 시험은 그 Decimal(v / 10^N)을 `.Nf`로 쓴 것과 견준다(무작위 형식의 `d` 열에 다섯 중 + 둘 꼴로 자릿수). i64의 `.2f`는 진단이 `.2d`를 가리킨다. + - TPC-C: 돈은 i64의 센트다(창고·구역의 ytd, 고객의 잔고와 ytd 지불, 상품 가격, 주문 줄과 기록의 금액, Payment의 금액). 세율과 + 할인율은 i64의 만분율이다. SQLite도 INTEGER 열과 int64 바인딩이다. 초기 데이터는 정수로 뽑고(가격 100–10,000센트 등), 적재는 i64 + 칸을 2의 보수로 싼다. 견주기는 이제 오차 없는 같음이다(1e-9의 상대 오차를 지웠다). 2만 트랜잭션 뒤 모든 표의 모든 행이 + 같고(묶은 SQLite도), 3.3.2의 일관성 조건이 양쪽에서 선다. 막대가 더 굳어졌다: 같음이 정확하다. + - 008: NUM_TEXT의 10진 자릿수, 메시지 행의 i64 칸(2의 보수, 리틀 엔디언 8바이트). aup의 002: `.Nd`. + - 명령 수(b45 대 b44): 실행기만의 BFS +0.09%, 나머지 ±0.001% 안이다. 은행 질의(s44와 s45를 한 번에 번갈아 여섯 번의 중앙값)는 + in_credit −0.59%, per_branch −0.34%, ranks −0.20%, 나머지 ±0.01% 안이다. 일곱 질의의 답은 두 빌드에서 바이트까지 같다. **순서의 까닭.** - 1과 2가 묶음의 명세 대부분을 연다. 가장 값이 크다. |
