cb424d7448
verify-patch-sanity.py validates every active recipe .patch has internally- consistent hunk line counts — catching the 'malformed patch at line N' failure at commit/CI/preflight time instead of hours into a cook. This cycle hit that class three times (qtwaylandscanner, sddm, xwayland), each only discovered when cookbook tried to apply the patch. Running it across the repo found 29 latent malformed patches (validated against GNU patch: e.g. relibc/P3-sysv-ipc reproduces 'malformed patch at line 22'). They were harmless only because they sit in vendored recipes (baked, not re- applied) — but would fail on any version-bump re-derivation. --fix recounts the hunk headers (body untouched) and repaired all 29. Wired into build-preflight.sh (Phase 1.0D) and redbear-ci.yml, with a unit test (test-patch-sanity.sh). Skips archived/legacy trees and unvalidatable formats (empty placeholders, bare-@@ git hunks).
31 lines
1.0 KiB
C
31 lines
1.0 KiB
C
// REQUIRES: x86-registered-target
|
|
// RUN: %clang_cc1 %s -triple i386-apple-darwin10 -fasm-blocks -emit-llvm -o - | FileCheck %s --check-prefix=DARWIN
|
|
// RUN: %clang_cc1 %s -triple i686-pc-win32 -fasm-blocks -emit-llvm -o - | FileCheck %s --check-prefix=WINDOWS
|
|
|
|
// On Windows, .align is in bytes, and on Darwin, .align is in log2 form. The
|
|
// Intel inline assembly parser should rewrite to the appropriate form depending
|
|
// on the platform.
|
|
|
|
void align_test(void) {
|
|
__asm align 8
|
|
__asm align 16;
|
|
__asm align 128;
|
|
__asm ALIGN 256;
|
|
}
|
|
|
|
// DARWIN-LABEL: define{{.*}} void @align_test()
|
|
// DARWIN: call void asm sideeffect inteldialect
|
|
// DARWIN-SAME: .align 3
|
|
// DARWIN-SAME: .align 4
|
|
// DARWIN-SAME: .align 7
|
|
// DARWIN-SAME: .align 8
|
|
// DARWIN-SAME: "~{dirflag},~{fpsr},~{flags}"()
|
|
|
|
// WINDOWS-LABEL: define dso_local void @align_test()
|
|
// WINDOWS: call void asm sideeffect inteldialect
|
|
// WINDOWS-SAME: .align 8
|
|
// WINDOWS-SAME: .align 16
|
|
// WINDOWS-SAME: .align 128
|
|
// WINDOWS-SAME: .align 256
|
|
// WINDOWS-SAME: "~{dirflag},~{fpsr},~{flags}"()
|