78 Commits

Author SHA1 Message Date
Roland Westrelin
3636d8f3d5 8161147: jvm crashes when -XX:+UseCountedLoopSafepoints is enabled
Don't convert loop with safepoint on the backedge to Counted loop

Reviewed-by: kvn
2016-07-25 14:31:42 -07:00
Tobias Hartmann
6294f0770b 8159715: Fix for 8072422 is incorrect
Fixed several issues introduced by 8072422.

Reviewed-by: zmajo, kvn
2016-06-20 09:32:44 +02:00
Michael Berg
64cf7e6b6f 8153998: Masked vector post loops
Masked vectorization for post loops to execute in a single iteration in place of fixup scalar loops which used to take many iterations to complete work for user loops.

Reviewed-by: twisti, kvn
2016-04-18 15:18:14 -07:00
Bharadwaj Yadavalli
cecf2d83d5 Merge 2016-04-08 12:36:27 -04:00
Michael Berg
ff80cc58c9 8151573: Multiversioning for range check elimination
Range check elimination in post loops

Reviewed-by: kvn
2016-04-05 10:34:05 -07:00
Joseph Provino
5cef85023b 8132524: Missing includes to resourceArea.hpp
Files that use ResourceMark are missing the include of resourceArea.hpp

Reviewed-by: tschatzl, jwilhelm
2016-04-04 12:57:48 -04:00
Zoltan Majo
69d14c811b 8072422: Cleanup: Remove some unused flags/code in loop optimizations
Remove unused flags, change test using them.

Reviewed-by: kvn, twisti
2016-04-04 12:52:11 +02:00
Zoltan Majo
5751808a6c 8148754: C2 loop unrolling fails due to unexpected graph shape
Check if graph shape is appropriate for optimization, bail out optimization if not.

Reviewed-by: kvn, twisti, shade, dnsimon
2016-03-21 09:51:20 +01:00
Roland Westrelin
1462f0b038 8147645: get_ctrl_no_update() code is wrong
Array.fill intrinsification code doesn't mark replaced control as dead

Reviewed-by: kvn
2016-02-03 10:58:50 +01:00
Tobias Hartmann
69b52aa28b 8146629: Make phase->is_IterGVN() accessible from Node::Identity and Node::Value
Change arguments of Node::Identity() and Node::Value() from PhaseTransform* to PhaseGVN*.

Reviewed-by: kvn, roland
2016-01-12 12:55:09 +01:00
Roland Westrelin
631c143469 8145322: Code generated from unsafe loops can be slightly improved
Improve code generated from checkIndex and unsafe loops

Reviewed-by: kvn, thartmann
2016-01-11 16:33:27 +01:00
Tobias Hartmann
0f67aad7af 8144487: PhaseIdealLoop::build_and_optimize() must restore major_progress flag if skip_loop_opts is true
Restore the major_progress flag before calling igvn.optimize().

Reviewed-by: kvn
2015-12-21 11:34:58 +01:00
Vladimir Ivanov
afeb87ddd8 8144935: C2: safepoint is pruned from a non-counted loop
Reviewed-by: roland
2015-12-10 14:51:53 +03:00
Andreas Eriksson
c64b2175e7 6869327: Add new C2 flag to keep safepoints in counted loops
Reviewed-by: kvn, shade
2015-12-04 14:06:38 +01:00
Roland Westrelin
baaa8f79ed 8042997: Make intrinsic some or all check index/range methods
Objects.checkIndex() intrinsic

Reviewed-by: vlivanov, shade
2015-11-16 09:55:25 +01:00
Christian Thalinger
6896030b96 8140424: don't prefix developer and notproduct flag variables with CONST_ in product builds
Reviewed-by: goetz, stefank
2015-11-11 16:32:17 -10:00
Tobias Hartmann
7af927f9c1 8141132: JEP 254: Compact Strings
Adopt a more space-efficient internal representation for strings.

Co-authored-by: Brent Christian <brent.christian@oracle.com>
Co-authored-by: Vivek Deshpande <vivek.r.deshpande@intel.com>
Co-authored-by: Charlie Hunt <charlie.hunt@oracle.com>
Co-authored-by: Vladimir Kozlov <vladimir.kozlov@oracle.com>
Co-authored-by: Roger Riggs <roger.riggs@oracle.com>
Co-authored-by: Xueming Shen <xueming.shen@oracle.com>
Co-authored-by: Aleksey Shipilev <aleksey.shipilev@oracle.com>
Co-authored-by: Sandhya Viswanathan <sandhya.viswanathan@intel.com>
Reviewed-by: alanb, bdelsart, coleenp, iklam, jiangli, jrose, kevinw, naoto, pliden, roland, smarks, twisti
2015-11-03 09:41:03 +01:00
Tobias Hartmann
6479241f4a 8135252: IdealLoopTree::dump_head() prints negative trip count
IdealLoopTree::dump_head() should not cast float to int.

Reviewed-by: kvn
2015-09-14 10:00:26 +02:00
Roland Westrelin
96b004cd82 8080289: Intermediate writes in a loop not eliminated by optimizer
Move Stores out of loop (after or before) when possible

Reviewed-by: kvn, vlivanov
2015-07-29 17:25:04 +02:00
Vlad Ureche
645a55a98f 8011858: Use Compile::live_nodes() instead of Compile::unique() in appropriate places
Reviewed-by: kvn, vlivanov
2015-08-10 10:39:19 -07:00
Jan Civlin
2a4f18ccbd 8085932: Fixing bugs in detecting memory alignments in SuperWord
Reviewed-by: kvn
2015-07-14 09:55:22 -07:00
Vladimir Kozlov
b5284a93ce 8129920: Vectorized loop unrolling
Optimize loop opts for vectorizible loops.

Reviewed-by: kvn, roland
2015-07-10 11:59:09 -07:00
Michael Berg
7c7b91845f 8080325: SuperWord loop unrolling analysis
Determine loop unroll factor based on supported vectors sizes.

Reviewed-by: roland, kvn
2015-06-16 16:10:36 -07:00
Jan Civlin
c7d33de202 8076284: Improve vectorization of parallel streams
Improve vectorization of java/util/stream/Streams$RangeIntSpliterator::forEachRemaining() method and enable loop vectorization in a given method on demand.

Reviewed-by: kvn
2015-05-05 12:33:57 -07:00
Igor Veresov
783f2be52f 8072753: Nondeterministic wrong answer on arithmetic
Check for overflow when inverting the loop during the counted loop conversion

Reviewed-by: kvn
2015-02-17 11:00:18 -08:00
Vladimir Ivanov
5fd1e54fc1 8067338: compiler/debug/TraceIterativeGVN.java segfaults
Reviewed-by: kvn
2014-12-19 16:42:40 -08:00
Tobias Hartmann
11eb4553c9 8040213: C2 does not put all modified nodes on IGVN worklist
Verification code is added that checks if modified nodes are put on the IGVN worklist and modified nodes are processed by 'PhaseIterGVN::transform_old()'

Reviewed-by: kvn, jrose
2014-07-25 10:06:17 +02:00
Tobias Hartmann
2a0815a55e 8034812: remove IDX_INIT macro hack in Node class
The IDX_INIT macro used by Node::Node(...) to retrieve the Compile object is removed and replaced by a call to Compile::current(). The Node constructor, new operator and all calls to it are adapted accordingly.

Reviewed-by: kvn, jrose, iveresov, goetz
2014-06-02 08:07:29 +02:00
David Chase
305ec3bd3f 8037816: Fix for 8036122 breaks build with Xcode5/clang
Repaired or selectively disabled offending formats; future-proofed with additional checking

Reviewed-by: kvn, jrose, stefank
2014-05-09 16:50:54 -04:00
Vladimir Kozlov
c909ac41de 8039298: assert(base == NULL || t_adr->isa_rawptr() || !phase->type(base)->higher_equal(TypePtr::NULL_PTR))
Convert the assert into the runtime check to skip IGVN optimizations for problematic memory nodes. Eliminate dead nodes more aggressively.

Reviewed-by: twisti, iveresov
2014-05-02 16:44:54 -07:00
Vladimir Kozlov
8badeecc2c 8039050: Crash in C2 compiler at Node::rematerialize
Added missing calls to record_for_igvn() in loop opts. Added verification of def-use domination.

Reviewed-by: iveresov
2014-04-15 14:34:48 -07:00
Morris Meyer
6db303a301 8001532: C2 node files refactoring
Split C2 node files into cast, convert, countbits, intrinsic, move, narrowptr and opaquenode classes

Reviewed-by: kvn, morris
2014-04-01 09:05:20 -07:00
Roland Westrelin
3f8ae3e9b9 8024069: replace_in_map() should operate on parent maps
Type information gets lost because replace_in_map() doesn't update parent maps

Reviewed-by: kvn, twisti
2013-10-19 12:16:43 +02:00
Staffan Larsen
718f3252f6 8005849: JEP 167: Event-Based JVM Tracing
Co-authored-by: Karen Kinnear <karen.kinnear@oracle.com>
Co-authored-by: Bengt Rutisson <bengt.rutisson@oracle.com>
Co-authored-by: Calvin Cheung <calvin.cheung@oracle.com>
Co-authored-by: Erik Gahlin <erik.gahlin@oracle.com>
Co-authored-by: Erik Helin <erik.helin@oracle.com>
Co-authored-by: Jesper Wilhelmsson <jesper.wilhelmsson@oracle.com>
Co-authored-by: Keith McGuigan <keith.mcguigan@oracle.com>
Co-authored-by: Mattias Tobiasson <mattias.tobiasson@oracle.com>
Co-authored-by: Markus Gronlund <markus.gronlund@oracle.com>
Co-authored-by: Mikael Auno <mikael.auno@oracle.com>
Co-authored-by: Nils Eliasson <nils.eliasson@oracle.com>
Co-authored-by: Nils Loodin <nils.loodin@oracle.com>
Co-authored-by: Rickard Backman <rickard.backman@oracle.com>
Co-authored-by: Stefan Karlsson <stefan.karlsson@oracle.com>
Co-authored-by: Yekaterina Kantserova <yekaterina.kantserova@oracle.com>
Reviewed-by: acorn, coleenp, sla
2013-06-10 11:30:51 +02:00
Vladimir Kozlov
848ccdbdfe 8004640: C2 assert failure in memnode.cpp: NULL+offs not RAW address
Always transform AddP nodes in IdealKit by calling _gvn.transform().

Reviewed-by: roland, twisti
2013-03-26 12:55:26 -07:00
Roland Westrelin
c401bf065d 7197327: 40% regression on 8 b41 comp 8 b40 on specjvm2008.mpegaudio on oob
Add support for expensive nodes.

Reviewed-by: kvn
2013-02-12 12:56:11 +01:00
Vladimir Ivanov
b1d745897b 8000313: C2 should use jlong for 64bit values
Replace all occurrences of long with jlong in C2 code.

Reviewed-by: kvn, twisti
2012-10-08 13:02:13 -07:00
Bharadwaj Yadavalli
d5d2e78faa 7193318: C2: remove number of inputs requirement from Node's new operator
Deleted placement new operator of Node - node(size_t, Compile *, int).

Reviewed-by: kvn, twisti
2012-09-27 09:38:42 -07:00
Vladimir Kozlov
da65cc4532 7160161: Missed safepoint in non-Counted loop
Do not remove safepoints during peeling optimization.

Reviewed-by: twisti
2012-08-29 13:02:40 -07:00
Vladimir Kozlov
e3c3c8527e 6340864: Implement vectorization optimizations in hotspot-server
Added asm encoding and mach nodes for vector arithmetic instructions on x86.

Reviewed-by: roland
2012-08-20 09:07:21 -07:00
Vladimir Kozlov
d1191bb4f4 7119644: Increase superword's vector size up to 256 bits
Increase vector size up to 256-bits for YMM AVX registers on x86.

Reviewed-by: never, twisti, roland
2012-06-15 01:25:19 -07:00
Vlaidmir Ivanov
dd85e2f356 7173340: C2: code cleanup: use PhaseIterGVN::replace_edge(Node*, int, Node*) where applicable
Replace frequent C2 optimizer code patterns with new methods calls

Reviewed-by: kvn, twisti
2012-06-12 16:23:31 -07:00
Deepak Bhole
ce79f12b7b 7140882: Don't return booleans from methods returning pointers
Changed "return false" to "return NULL"

Reviewed-by: dholmes, rottenha
2012-01-30 12:36:49 +01:00
Vladimir Kozlov
f3f36ae094 7064302: JDK7 build 147 crashed after testing my java 6-compiled web app
Don't split CMove node if it's control edge is different from split region.

Reviewed-by: never
2012-01-12 12:28:59 -08:00
Vladimir Kozlov
8d2ee23293 6890673: Eliminate allocations immediately after EA
Try to eliminate allocations and related locks immediately after escape analysis.

Reviewed-by: never
2011-11-16 09:13:57 -08:00
Vladimir Kozlov
157ba53d27 7110586: C2 generates incorrect results
Exact limit of empty loop calculated incorrectly.

Reviewed-by: iveresov, never
2011-11-10 20:17:05 -08:00
Vladimir Kozlov
09b7902e14 7107042: assert(no_dead_loop) failed: dead loop detected
Use dead nodes elimination code in PhaseIdealLoop before executing EA.

Reviewed-by: never, twisti
2011-11-09 07:25:51 -08:00
Vladimir Kozlov
92b2b44b18 7035946: Up to 15% regression on JDK 7 b136 vs b135 on specjvm2008.crypto.rsa on x64
Revert changes which caused regression.

Reviewed-by: never
2011-09-09 13:47:11 -07:00
Vladimir Kozlov
52f678435a 7077439: Possible reference through NULL in loopPredicate.cpp:726
Use cl->is_valid_counted_loop() check.

Reviewed-by: never
2011-08-10 14:06:57 -07:00
Vladimir Kozlov
df8d608ac7 7068051: SIGSEGV in PhaseIdealLoop::build_loop_late_post
Removed predicate cloning from loop peeling optimization and from split fall-in paths.

Reviewed-by: never
2011-07-29 09:16:29 -07:00