Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
PHP Episodio VII: El Despertar de la Fuerza
Search
César Suárez Ortega
February 24, 2016
Programming
1
220
PHP Episodio VII: El Despertar de la Fuerza
César Suárez Ortega
February 24, 2016
Tweet
Share
More Decks by César Suárez Ortega
See All by César Suárez Ortega
Symfony y concurrencia: el componente Lock
csuarez
0
890
Consumiendo una API REST con AngularJS
csuarez
0
270
Construyendo una API REST con Python y MongoDB
csuarez
0
240
Automatización de tareas con Ansible
csuarez
1
320
Procesanso datos con Hadoop: MapReduce y YARN
csuarez
0
310
Introducción a SCRUM
csuarez
0
240
Introducción a GIT
csuarez
1
160
Using CAD Systems and E-Learning in radiologist training
csuarez
0
70
CETA-CIEMAT: Salud + Investigación
csuarez
0
76
Other Decks in Programming
See All in Programming
あなたのアプリ、ログはでてますか?あるいはログをだしてますか? (Funabashi.dev用 軽量版)
uzulla
2
110
メモリ最適化を究める!iOSアプリ開発における5つの重要なポイント
yhirakawa333
0
410
Debugging: All you need to know (for simultaneous interpreting)
jmatsu
2
720
月間4.5億回再生を超える大規模サービス TVer iOSアプリのリアーキテクチャ戦略 - iOSDC2024
techtver
PRO
1
870
Web技術を駆使してユーザーの画面を「録画」する
yukukotani
13
6.6k
私のEbitengineの第一歩
qt_luigi
0
440
GoのIteratorに詳しくなってしまう
inatonix
1
200
[DroidKaigi 2024] Android ViewからJetpack Composeへ 〜Jetpack Compose移行のすゝめ〜 / From Android View to Jetpack Compose: A Guide to Migration
syarihu
1
420
Boost Performance and Developer Productivity with Jakarta EE 11
ivargrimstad
0
400
Method Swizzlingを行うライブラリにおけるマルチモジュール設計
yoshikma
0
110
Swift Concurrencyとレースコンディション
objectiveaudio
1
410
Scala におけるコンパイラエラーとの付き合い方
chencmd
2
420
Featured
See All Featured
Happy Clients
brianwarren
96
6.6k
The Cult of Friendly URLs
andyhume
76
6k
The World Runs on Bad Software
bkeepers
PRO
64
11k
Rails Girls Zürich Keynote
gr2m
93
13k
Ruby is Unlike a Banana
tanoku
96
11k
Designing Experiences People Love
moore
138
23k
Adopting Sorbet at Scale
ufuk
73
8.9k
Navigating Team Friction
lara
183
13k
The Art of Programming - Codeland 2020
erikaheidi
48
13k
It's Worth the Effort
3n
182
27k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
24
600
Designing Dashboards & Data Visualisations in Web Apps
destraynor
227
52k
Transcript
None
None
csuarez tharandur BEET.TECH
None
None
None
None
None
Novedades en PHP 5.x PHP 5.3 Namespaces: use keyword Closures
PHP 5.4 Traits Built-in server
Novedades en PHP 5.x PHP 5.5 Generators finally keyword PHP
5.6 Variadic functions: ... Keyword phpdbg
None
None
Hiphop HPHPc Compilador de PHP a C++ En tiempo de
ejecución (JIT compiler) HPHPi Intérprete para desarrollo Descontinuado
Hiphop vs PHP 5 http://php.webtutor.pl/en/2011/05/17/drupal-hiphop-for-php-vs-apc-benchmark/
None
hhvm Máquina virtual ¡No es un conversor de código! Compilador
JIT: PHP a byte code (HHBC) HHBC en código máquina x64 Optimización al vuelo Detección de zonas calientes
Hhvm vs hpHpC http://hhvm.com/blog/2027/faster-and-cheaper-the-evolution-of-the-hhvm-jit
Hhvm parity http://hhvm.com/blog/2813/we-are-the-98-5-and-the-16
Caso real: etSy https://codeascraft.com/2015/04/06/experimenting-with-hhvm-at-etsy/
Caso real: etSy https://codeascraft.com/2015/04/06/experimenting-with-hhvm-at-etsy/ La migración no es trivial Problemas
con las extensiones
Caso real: wikipedia https://blog.wikimedia.org/2014/12/29/how-we-made-editing-wikipedia-twice-as-fast/ Ahorro en infraestructuras Ayuda directa de
Facebook
None
Hack Superconjunto de PHP HHVM ejecuta Hack y PHP https://learnxinyminutes.com/docs/hack/
Hack
Hack
None
None
performance https://kinsta.com/blog/the-definitive-php-7-final-version-hhvm-benchmark/
performance https://kinsta.com/blog/the-definitive-php-7-final-version-hhvm-benchmark/
performance https://kinsta.com/blog/the-definitive-php-7-final-version-hhvm-benchmark/
performance https://kinsta.com/blog/the-definitive-php-7-final-version-hhvm-benchmark/
Scalar Type Hints <?php declare(strict_types=1); class ElePHPant { public $name,
$age, $cuteness, $evil; public function __construct(string $name, int $age, float $cuteness, bool $evil) { $this->name = $name; $this->age = $age; $this->cuteness = $cuteness; $this->evil = $evil; } }
ReturN Type Hints <?php function foo(): array { return [];
} function foo2(): DateTime { return null; // invalid } function &array_sort(array &$data): array { return $data; }
Spaceship operatoR // Si $a < $b devuelve -1 //
Si $a = $b devuelve 0 // Si $a > $b devuelve 1 function compare(int $a, int $b): int { return $a <=> $b; } unicode codePoint echo "\u{9999}"; //prints 香
Null coalesce operator $var = $value1 ?? $value2 ?? $value3;
Bind closure on Call $three = new Value(3); $four = new Value(4); $closure = function ($delta) { var_dump($this->getValue() + $delta); }; $closure->call($three, 4); // prints 7 $closure->call($four, 4); // prints 8
Group use declarations use Doctrine\Common\Collections\Expr\Comparison; use Doctrine\Common\Collections\Expr\Value; use Doctrine\Common\Collections\Expr\CompositeExpression; use
Doctrine\Common\Collections\Expr\{ Comparison, Value, CompositeExpression }; Anonymous classes $util->setLogger(new class { public function log($msg) { echo $msg; } });
Engine exceptions BaseException (abstract) ├── Exception extends BaseException ├── ErrorException
extends Exception └── RuntimeException extends Exception └── EngineException extends BaseException ├── TypeException extends EngineException ├── ParseException extends EngineException └── AssertionError extends EngineException
gracias