Gráfico de Commits

11 Commits

Autor SHA1 Mensagem Data
ptarjan 6b61441bd9 more isStatic fixed for closures
The interpreter fix was different than the jit/ir fix because ##translateFPushObjMethodD()##'s ##i.inputs[0]->rtt.valueClass()## is null (with a TODO in the code to make it not null). It then goes into the slowpath.

Another one like this and I think I should have a different attribute for static closures :(
2013-03-25 12:44:12 -07:00
alia 9690cc4f52 Fixed problems with HHIR's LdObjMethod instruction
This diff fixes problems with FPushObjMethodD stack unwinding, to HHIR.
This diff simply moves the try-catch into the methodCacheSlowPath.
This should also improve the code generated by gcc for the fast path.
2013-03-19 14:11:11 -07:00
alia 59e537b127 Inlined the fast-path of FPushObjMethodD in the IR.
Inlined the fast-path of FPushObjMethodD in the IR from
MethodCache::lookup. This should reduce the number of times we call
the MethodCache::lookup helper by inlining the common case where the
object's class hits in the target cache.
2013-03-18 15:12:16 -07:00
aalexandre 26178124a4 Eliminate int32, uint32, int16, uint16, int8, uint8.
This concludes the inttypes replacement.
These replacement have been mostly mechanical
with the use of cxx_replace.
2013-03-09 10:25:16 -08:00
mwilliams 4eaf40d7aa Generate g_class_map directly from the idl
This is the last step to being able to get rid of the c++ code
gen in hphp. "make -Chphp/system" is now a no-op.

I'll rip out the actual c++ generating code as a separate diff.
2013-03-08 17:52:31 -08:00
alia 6aa9f21425 Implemented globals in HHIR.
Implemented globals in HHIR (CGetG, SetG, VGetG, BindG,
IssetG, EmptyG). This version doesn't use the targetcache.
2013-03-05 22:07:57 -08:00
aalexandre b3b41e08bb Replaced NULL with nullptr 2013-02-19 06:57:54 -08:00
alia 5662a67f12 Cleaned up and added functionality to HHIR's handling of static properties and classes.
Broke LdClsPropAddr into 2 instructions by introducing a
ldClsPropAddrCached. LdClsPropAddrCached loads the static property via
the target cache so requires the class and property name to be
compile-time constants. LdClsPropAddr does not use the target cache
and works even if the property and class names are not constant.

Similarly broke LdCls into 2 by introducing LdClsCached. LdClsCached
uses the target cache to handle the case where the class name is a
compile time constant. Added code to detect cases where the class name
can be folded to a Class* constant.

Moved the code that decides between LdCls (LdClsPropAddr) and
LdClsCached (LdClsPropAddrCached) to the simplifier, allowing us to
optimize these instructions as optimization passes discover more
constants.

Changed HhbcTranslator code generation for AGet* and getClsPropAddr to
handle more cases using the above new instructions. Also improved
HhbcTranslator's translations for self and parent bytecodes.

Added a label to LdClsPropAddr to allow control flow when property is
not accessible. This enables implementation of IssetS (which was
incorrect before this diff) and EmptyS.

Implemented BindS, VGetS, EmptyS, and LateBoundCls.

Opportunitistically introduces calls to SSATmp::isA(...) to replace
explicit comparisons against Type::Tag values.

Moved AddElem punt from code generator to hhbctranslator so that we
can interpone.
2013-02-13 06:44:30 -08:00
smith d87811fd9b Support control flow in HHIR
Add support for in-trace control flow to HHIR.  To support
merging SSATmps, add support for 1+ sources to Jmp_ and
1+ destinations to DefLabel.  (One must use Jmp_ to pass
values to a label).

Every pass is affected by this.  The linearscan passes were
modified to visit blocks in reverse postorder (linear scan
should work even early blocks are not dominators of later
blocks).

Other passes had to be pessimized a bit because the dominator
assumption no longer holds.  Either they need to do full
dataflow analysis, be changed to do preorder traversals
down the dominator tree, changed to work only on a block
at a time, or fully disabled if control flow is detected.
2013-02-11 06:07:21 -08:00
ottoni 6a4ec5ae0e Implement FPushClsMethodF in HHIR 2013-02-11 03:44:05 -08:00
Jordan Delong 363d1bb20f Code move src/ -> hphp/
This change is mostly for FB internal organizational reasons.
Building is not effected beyond the fact that the target now
lands in hphp/hhvm/hhvm rather than src/hhvm/hhvm.
2013-02-11 02:10:41 -08:00