Hello Edson,
I made a few very minor changes to the Pascal source to make it more "parallel" to the javascript source and re-tested. Only the functions "EsPrimo" and "TareaLarga" have changes, most of the changes are in "EsPrimo".
program MedicionTiempo;
uses
SysUtils, Math;
{ Función para verificar si un número es primo }
function EsPrimo(num: LongInt): Boolean;
var
i: LongInt;
begin
if num <= 1 then exit(FALSE); // mod
//EsPrimo := False // mod
//else // mod
//begin // mod
//EsPrimo := True; // mod
for i := 2 to Trunc(Sqrt(num)) do
begin
if num mod i = 0 then
begin
exit(FALSE); // mod
//EsPrimo := False; // mod
//Break; // mod
end;
end;
exit(TRUE);
//end; // mod
end;
{ Función que simula una tarea compleja de cálculo (encontrar primos en un rango grande) }
procedure TareaLarga;
var
i, count: LongInt;
begin
count := 0;
for i := 2 to 1000000 - 1 do { same number as in js and c } // mod
begin
if EsPrimo(i) then
Inc(count); { Contar los números primos encontrados }
end;
WriteLn('Cantidad de números primos encontrados: ', count);
end;
var
StartTime, EndTime: TDateTime;
Tiempo: Double;
begin
{ Capturar el tiempo de inicio }
StartTime := Now;
{ Ejecutar la tarea larga }
TareaLarga;
{ Capturar el tiempo de finalización }
EndTime := Now;
{ Calcular el tiempo transcurrido en segundos }
Tiempo := (EndTime - StartTime) * 24 * 60 * 60; { Convertir de días a segundos }
{ Mostrar el tiempo de ejecución }
WriteLn('El tiempo de ejecución de TareaLarga() es: ', Tiempo:0:6, ' segundos');
WriteLn('El tiempo de ejecución de TareaLarga() en milisegundos es: ', Tiempo * 1000:0:3, ' ms');
end.
with the code above and testing multiple times and discarding the first time, I obtain an execution time of 0.157000 secs which would put FPC in first place

Note that I did _not_ make any changes to optimize the algorithm, it's just more "parallel" to the code for other languages than it previously was.
ETA:Highlighted single line change in TareaLarga.