Bug 957181
| Summary: | hawtjni: missing barriers in cache initialization | |||
|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Florian Weimer <fweimer> | |
| Component: | hawtjni | Assignee: | Marek Goldmann <mgoldman> | |
| Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | |
| Severity: | unspecified | Docs Contact: | ||
| Priority: | unspecified | |||
| Version: | 20 | CC: | java-sig-commits, mgoldman, mizdebsk | |
| Target Milestone: | --- | Keywords: | Reopened | |
| Target Release: | --- | |||
| Hardware: | Unspecified | |||
| OS: | Unspecified | |||
| URL: | https://github.com/fusesource/hawtjni/issues/7 | |||
| Whiteboard: | ||||
| Fixed In Version: | hawtjni-1.9-1.fc20 | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | ||
| Clone Of: | ||||
| : | 1009416 (view as bug list) | Environment: | ||
| Last Closed: | 2013-10-04 01:59:21 UTC | Type: | Bug | |
| Regression: | --- | Mount Type: | --- | |
| Documentation: | --- | CRM: | ||
| Verified Versions: | Category: | --- | ||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
| Cloudforms Team: | --- | Target Upstream Version: | ||
| Embargoed: | ||||
| Bug Depends On: | ||||
| Bug Blocks: | 957130, 1009416 | |||
A new version of HawtJNI was pushed to Rawhide. Could you please test this with 1.8? https://koji.fedoraproject.org/koji/taskinfo?taskID=5404838 Closing. Please reopen if the issue still exists. I do not see any changes to org.fusesource.hawtjni.generator. StructsGenerator.generateCacheFunction() in 1.8, so this issue still exists. Reported upstream: https://github.com/fusesource/hawtjni/issues/7 This bug appears to have been reported against 'rawhide' during the Fedora 20 development cycle. Changing version to '20'. More information and reason for this action is here: https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora20 hawtjni-1.9-1.fc20 has been submitted as an update for Fedora 20. https://admin.fedoraproject.org/updates/hawtjni-1.9-1.fc20 The hawtjni-1.9-1.fc20 update should fix the issue. Package hawtjni-1.9-1.fc20: * should fix your issue, * was pushed to the Fedora 20 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing hawtjni-1.9-1.fc20' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2013-17602/hawtjni-1.9-1.fc20 then log in and leave karma (feedback). hawtjni-1.9-1.fc20 has been pushed to the Fedora 20 stable repository. If problems still persist, please make note of it in this bug report. |
The following code is generated from the example: void cachebarFields(JNIEnv *env, jobject lpObject) { if (barFc.cached) return; barFc.clazz = env->GetObjectClass(lpObject); barFc.a = env->GetFieldID(barFc.clazz, "a", "I"); barFc.b = env->GetFieldID(barFc.clazz, "b", "J"); barFc.c = env->GetFieldID(barFc.clazz, "c", "[B"); barFc.c5 = env->GetFieldID(barFc.clazz, "c5", "B"); barFc.prev = env->GetFieldID(barFc.clazz, "prev", "J"); barFc.cached = 1; } There are no barriers, so readers may observe the write to the "cached" member before the other members. (One of the barFc.cached checks is redundant, BTW.)